From mboxrd@z Thu Jan 1 00:00:00 1970 Path: news.gmane.org!not-for-mail From: Eli Zaretskii Newsgroups: gmane.emacs.bugs Subject: bug#15983: 24.3; Emacs Not Killing Child Process Date: Sun, 22 Dec 2013 05:53:18 +0200 Message-ID: <83mwjt8rtd.fsf@gnu.org> References: <83ob4cbvot.fsf@gnu.org> <83txe2aad0.fsf@gnu.org> <834n629hhz.fsf@gnu.org> Reply-To: Eli Zaretskii NNTP-Posting-Host: plane.gmane.org X-Trace: ger.gmane.org 1387684511 14019 80.91.229.3 (22 Dec 2013 03:55:11 GMT) X-Complaints-To: usenet@ger.gmane.org NNTP-Posting-Date: Sun, 22 Dec 2013 03:55:11 +0000 (UTC) Cc: sjm@sjm.io, bozhidar.batsov@gmail.com, 15983@debbugs.gnu.org To: Joan Karadimov Original-X-From: bug-gnu-emacs-bounces+geb-bug-gnu-emacs=m.gmane.org@gnu.org Sun Dec 22 04:55:15 2013 Return-path: Envelope-to: geb-bug-gnu-emacs@m.gmane.org Original-Received: from lists.gnu.org ([208.118.235.17]) by plane.gmane.org with esmtp (Exim 4.69) (envelope-from ) id 1Vua8J-0005oz-Cq for geb-bug-gnu-emacs@m.gmane.org; Sun, 22 Dec 2013 04:55:15 +0100 Original-Received: from localhost ([::1]:56509 helo=lists.gnu.org) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1Vua8I-0000aY-T2 for geb-bug-gnu-emacs@m.gmane.org; Sat, 21 Dec 2013 22:55:14 -0500 Original-Received: from eggs.gnu.org ([2001:4830:134:3::10]:50323) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1Vua8B-0000Yr-VG for bug-gnu-emacs@gnu.org; Sat, 21 Dec 2013 22:55:13 -0500 Original-Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1Vua86-0000s1-MP for bug-gnu-emacs@gnu.org; Sat, 21 Dec 2013 22:55:07 -0500 Original-Received: from debbugs.gnu.org ([140.186.70.43]:48069) by eggs.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1Vua86-0000rZ-JS for bug-gnu-emacs@gnu.org; Sat, 21 Dec 2013 22:55:02 -0500 Original-Received: from Debian-debbugs by debbugs.gnu.org with local (Exim 4.80) (envelope-from ) id 1Vua85-000140-S6 for bug-gnu-emacs@gnu.org; Sat, 21 Dec 2013 22:55:02 -0500 X-Loop: help-debbugs@gnu.org Resent-From: Eli Zaretskii Original-Sender: "Debbugs-submit" Resent-CC: bug-gnu-emacs@gnu.org Resent-Date: Sun, 22 Dec 2013 03:55:01 +0000 Resent-Message-ID: Resent-Sender: help-debbugs@gnu.org X-GNU-PR-Message: followup 15983 X-GNU-PR-Package: emacs,w32 X-GNU-PR-Keywords: Original-Received: via spool by 15983-submit@debbugs.gnu.org id=B15983.13876844644033 (code B ref 15983); Sun, 22 Dec 2013 03:55:01 +0000 Original-Received: (at 15983) by debbugs.gnu.org; 22 Dec 2013 03:54:24 +0000 Original-Received: from localhost ([127.0.0.1]:33855 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.80) (envelope-from ) id 1Vua7T-00012z-DS for submit@debbugs.gnu.org; Sat, 21 Dec 2013 22:54:23 -0500 Original-Received: from mtaout20.012.net.il ([80.179.55.166]:61396) by debbugs.gnu.org with esmtp (Exim 4.80) (envelope-from ) id 1Vua7Q-00012m-Hy for 15983@debbugs.gnu.org; Sat, 21 Dec 2013 22:54:21 -0500 Original-Received: from conversion-daemon.a-mtaout20.012.net.il by a-mtaout20.012.net.il (HyperSendmail v2007.08) id <0MY600C00W0CZD00@a-mtaout20.012.net.il> for 15983@debbugs.gnu.org; Sun, 22 Dec 2013 05:53:30 +0200 (IST) Original-Received: from HOME-C4E4A596F7 ([87.69.4.28]) by a-mtaout20.012.net.il (HyperSendmail v2007.08) with ESMTPA id <0MY600C1HW55O380@a-mtaout20.012.net.il>; Sun, 22 Dec 2013 05:53:30 +0200 (IST) In-reply-to: X-012-Sender: halo1@inter.net.il X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.15 Precedence: list X-detected-operating-system: by eggs.gnu.org: GNU/Linux 3.x X-Received-From: 140.186.70.43 X-BeenThere: bug-gnu-emacs@gnu.org List-Id: "Bug reports for GNU Emacs, the Swiss army knife of text editors" List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: bug-gnu-emacs-bounces+geb-bug-gnu-emacs=m.gmane.org@gnu.org Original-Sender: bug-gnu-emacs-bounces+geb-bug-gnu-emacs=m.gmane.org@gnu.org Xref: news.gmane.org gmane.emacs.bugs:82383 Archived-At: > Date: Sun, 22 Dec 2013 04:03:12 +0200 > From: Joan Karadimov > Cc: 15983@debbugs.gnu.org, Simon Morgan , > Bozhidar Batsov > > > > I am aware that 'taskkill' is not present on windowses (is that a word?) > > > older than XP. This makes it no worse than 'CreateToolhelp32Snapshot'. > > > > No, the toolhelp functions are available on Windows 2000 and even on > > Windows 98. They are unavailable only on NT 4.0. > > > MSDN states that the "Minimum supported client" is XP. MSDN lies. They do that in a lot of API functions, to pretend that older versions don't exist (because their support has ended). > I guess 2000 is counted with the server ones No, it's not. > and 9x is not even considered. Right. > > > > This might be "good enough" -- we err on the safe side, and only leave > > > > some subprocesses not killed in rare situations. Does this strategy > > > > solve the problem which started this bug report? > > > > You didn't answer that question, but I assume the answer is YES. > > > It should fix the problem, yes. Well, I'd prefer a test, to be sure. > > I think it would be better to also require that process-start-time is > > before the time kill-process-tree is called. This might miss some > > children, if they happen to be spawned right after the call, but it is > > safer. > > > This should already be reflected in the requirement that all processes that > are killed were already in the initial-process-tree (the first snapshot). They could have been started before that. E.g., imagine that one of the children exited or died on its own, and its PID was reused, before kill-process was called. > I'll start working on some code that I can show, then. Thank you. Btw, if the patch is going to be substantial, we will need legal paperwork from you, before we can accept the code.