From mboxrd@z Thu Jan 1 00:00:00 1970 Path: news.gmane.org!not-for-mail From: Harald Hanche-Olsen Newsgroups: gmane.emacs.devel Subject: Re: proced: ppid of process ID 0 can be 0 Date: Mon, 22 Dec 2008 09:54:27 +0100 (CET) Message-ID: <20081222.095427.259439175.hanche@math.ntnu.no> References: NNTP-Posting-Host: lo.gmane.org Mime-Version: 1.0 Content-Type: Text/Plain; charset=us-ascii Content-Transfer-Encoding: 7bit X-Trace: ger.gmane.org 1229936087 18041 80.91.229.12 (22 Dec 2008 08:54:47 GMT) X-Complaints-To: usenet@ger.gmane.org NNTP-Posting-Date: Mon, 22 Dec 2008 08:54:47 +0000 (UTC) To: emacs-devel@gnu.org Original-X-From: emacs-devel-bounces+ged-emacs-devel=m.gmane.org@gnu.org Mon Dec 22 09:55:55 2008 Return-path: Envelope-to: ged-emacs-devel@m.gmane.org Original-Received: from lists.gnu.org ([199.232.76.165]) by lo.gmane.org with esmtp (Exim 4.50) id 1LEgZu-0007vm-80 for ged-emacs-devel@m.gmane.org; Mon, 22 Dec 2008 09:55:54 +0100 Original-Received: from localhost ([127.0.0.1]:44174 helo=lists.gnu.org) by lists.gnu.org with esmtp (Exim 4.43) id 1LEgYh-0001iT-IK for ged-emacs-devel@m.gmane.org; Mon, 22 Dec 2008 03:54:39 -0500 Original-Received: from mailman by lists.gnu.org with tmda-scanned (Exim 4.43) id 1LEgYd-0001iN-2Y for emacs-devel@gnu.org; Mon, 22 Dec 2008 03:54:35 -0500 Original-Received: from exim by lists.gnu.org with spam-scanned (Exim 4.43) id 1LEgYb-0001i9-2J for emacs-devel@gnu.org; Mon, 22 Dec 2008 03:54:34 -0500 Original-Received: from [199.232.76.173] (port=42175 helo=monty-python.gnu.org) by lists.gnu.org with esmtp (Exim 4.43) id 1LEgYa-0001i5-Vu for emacs-devel@gnu.org; Mon, 22 Dec 2008 03:54:33 -0500 Original-Received: from abel.math.ntnu.no ([129.241.15.50]:45995) by monty-python.gnu.org with smtp (Exim 4.60) (envelope-from ) id 1LEgYa-0003AZ-Dy for emacs-devel@gnu.org; Mon, 22 Dec 2008 03:54:32 -0500 Original-Received: (qmail 21412 invoked from network); 22 Dec 2008 08:54:28 -0000 Original-Received: from gauss.math.ntnu.no (HELO localhost) (hanche@129.241.15.102) by abel.math.ntnu.no with ESMTPA; 22 Dec 2008 08:54:28 -0000 In-Reply-To: X-URL: http://www.math.ntnu.no/~hanche/ X-Mailer: Mew version 6.1.53 on Emacs 23.0.60 / Mule 6.0 (HANACHIRUSATO) X-detected-operating-system: by monty-python.gnu.org: Solaris 8 (1) X-BeenThere: emacs-devel@gnu.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: "Emacs development discussions." List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Original-Sender: emacs-devel-bounces+ged-emacs-devel=m.gmane.org@gnu.org Errors-To: emacs-devel-bounces+ged-emacs-devel=m.gmane.org@gnu.org Xref: news.gmane.org gmane.emacs.devel:107172 Archived-At: + Eli Zaretskii : >> I.e. under POSIX, they should treat a "ppid == 0" as meaning that >> there's no parent (i.e. the data returned to Elisp should never say "the >> parent is process 0" but should instead say "this process doesn't have >> a parent"). > > [...] > > Btw, is the above really mandated by Posix? Any references to that? FWIW, on FreeBSD there is process 0 (the swapper), and various kernel processes have process 0 as their parent. ; pstree 0 -+= 00000 root [swapper] |-+= 00001 root /sbin/init -- | |--= 00354 _dhcp dhclient: em0 (dhclient) | |--= 00623 root /sbin/devd .... .... |--- 00002 root [g_event] |--- 00003 root [g_up] |--- 00004 root [g_down] |--- 00005 root [system_taskq] |--- 00006 root [system_taskq] |--- 00007 root [acpi_task_0] .... .... Of course, it may be that you really don't want emacs to see kernel processes at all. - Harald