From mboxrd@z Thu Jan 1 00:00:00 1970 X-Msuck: nntp://news.gmane.org/gmane.linux.lib.musl.general/10280 Path: news.gmane.org!not-for-mail From: Laurent Bercot Newsgroups: gmane.linux.lib.musl.general Subject: Re: abort() fails to terminate PID 1 process Date: Sun, 3 Jul 2016 22:20:46 +0200 Message-ID: <4f7df3fa-ed15-5650-b26f-47c5225bfbf3@skarnet.org> References: <20160620100443.GV22574@port70.net> <20160620194110.GM10893@brightrain.aerifal.cx> <20160703135846.GF15995@brightrain.aerifal.cx> <82c4150b-3433-4e3f-2304-9aceef82a54b@skarnet.org> <20160703200125.GJ15995@brightrain.aerifal.cx> Reply-To: musl@lists.openwall.com NNTP-Posting-Host: plane.gmane.org Mime-Version: 1.0 Content-Type: text/plain; charset=utf-8; format=flowed Content-Transfer-Encoding: 7bit X-Trace: ger.gmane.org 1467577259 2936 80.91.229.3 (3 Jul 2016 20:20:59 GMT) X-Complaints-To: usenet@ger.gmane.org NNTP-Posting-Date: Sun, 3 Jul 2016 20:20:59 +0000 (UTC) To: musl@lists.openwall.com Original-X-From: musl-return-10293-gllmg-musl=m.gmane.org@lists.openwall.com Sun Jul 03 22:20:55 2016 Return-path: Envelope-to: gllmg-musl@m.gmane.org Original-Received: from mother.openwall.net ([195.42.179.200]) by plane.gmane.org with smtp (Exim 4.69) (envelope-from ) id 1bJnsr-0000lh-R9 for gllmg-musl@m.gmane.org; Sun, 03 Jul 2016 22:20:53 +0200 Original-Received: (qmail 18036 invoked by uid 550); 3 Jul 2016 20:20:52 -0000 Mailing-List: contact musl-help@lists.openwall.com; run by ezmlm Precedence: bulk List-Post: List-Help: List-Unsubscribe: List-Subscribe: List-ID: Original-Received: (qmail 18017 invoked from network); 3 Jul 2016 20:20:51 -0000 User-Agent: Mozilla/5.0 (Windows NT 10.0; WOW64; rv:45.0) Gecko/20100101 Thunderbird/45.1.1 In-Reply-To: <20160703200125.GJ15995@brightrain.aerifal.cx> Xref: news.gmane.org gmane.linux.lib.musl.general:10280 Archived-At: On 03/07/2016 22:01, Rich Felker wrote: > No. Halting the system safely (which kernel panic does) is completely > different from runaway wrong-code execution, and the only reason we > don't have runaway wrong-code execution right now is because I built > in the for(;;) safety in case termination failed. Halting the system, no matter how safely, is also completely different from cleanly terminating the aborting process (while not impacting other processes as is supposed to be guaranteed by Unix). At this point, we're wildly outside the realm of specification anyway, and I find it acceptable to say that pid 1 abort (or any kind of death for that matter) is UB. Your choice of implementation for abort() is good and safe, but I think it's just QoI, not something you're bound to do by a standard. -- Laurent