From mboxrd@z Thu Jan 1 00:00:00 1970 Path: news.gmane.org!.POSTED!not-for-mail From: Noam Postavsky Newsgroups: gmane.emacs.bugs Subject: bug#15695: 24.3; multiple async shell commands at once run randomly Date: Mon, 02 Apr 2018 19:49:27 -0400 Message-ID: <87sh8dnp88.fsf@gmail.com> References: <877gd3ofhy.fsf@yahoo.fr> <87wp00ixfx.fsf@users.sourceforge.net> NNTP-Posting-Host: blaine.gmane.org Mime-Version: 1.0 Content-Type: text/plain X-Trace: blaine.gmane.org 1522712899 28981 195.159.176.226 (2 Apr 2018 23:48:19 GMT) X-Complaints-To: usenet@blaine.gmane.org NNTP-Posting-Date: Mon, 2 Apr 2018 23:48:19 +0000 (UTC) User-Agent: Gnus/5.13 (Gnus v5.13) Emacs/26.0.90 (gnu/linux) Cc: Nicolas Richard To: 15695@debbugs.gnu.org Original-X-From: bug-gnu-emacs-bounces+geb-bug-gnu-emacs=m.gmane.org@gnu.org Tue Apr 03 01:48:15 2018 Return-path: Envelope-to: geb-bug-gnu-emacs@m.gmane.org Original-Received: from lists.gnu.org ([208.118.235.17]) by blaine.gmane.org with esmtp (Exim 4.84_2) (envelope-from ) id 1f39BM-0007P4-V9 for geb-bug-gnu-emacs@m.gmane.org; Tue, 03 Apr 2018 01:48:13 +0200 Original-Received: from localhost ([::1]:44474 helo=lists.gnu.org) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1f39DO-0000k2-OO for geb-bug-gnu-emacs@m.gmane.org; Mon, 02 Apr 2018 19:50:18 -0400 Original-Received: from eggs.gnu.org ([2001:4830:134:3::10]:58586) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1f39DD-0000jQ-B8 for bug-gnu-emacs@gnu.org; Mon, 02 Apr 2018 19:50:08 -0400 Original-Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1f39D8-00066m-El for bug-gnu-emacs@gnu.org; Mon, 02 Apr 2018 19:50:07 -0400 Original-Received: from debbugs.gnu.org ([208.118.235.43]:55935) by eggs.gnu.org with esmtps (TLS1.0:RSA_AES_128_CBC_SHA1:16) (Exim 4.71) (envelope-from ) id 1f39D8-00065n-B6 for bug-gnu-emacs@gnu.org; Mon, 02 Apr 2018 19:50:02 -0400 Original-Received: from Debian-debbugs by debbugs.gnu.org with local (Exim 4.84_2) (envelope-from ) id 1f39D7-0002ek-VJ for bug-gnu-emacs@gnu.org; Mon, 02 Apr 2018 19:50:01 -0400 X-Loop: help-debbugs@gnu.org Resent-From: Noam Postavsky Original-Sender: "Debbugs-submit" Resent-CC: bug-gnu-emacs@gnu.org Resent-Date: Mon, 02 Apr 2018 23:50:01 +0000 Resent-Message-ID: Resent-Sender: help-debbugs@gnu.org X-GNU-PR-Message: followup 15695 X-GNU-PR-Package: emacs X-GNU-PR-Keywords: confirmed Original-Received: via spool by 15695-submit@debbugs.gnu.org id=B15695.152271297610174 (code B ref 15695); Mon, 02 Apr 2018 23:50:01 +0000 Original-Received: (at 15695) by debbugs.gnu.org; 2 Apr 2018 23:49:36 +0000 Original-Received: from localhost ([127.0.0.1]:35599 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1f39Ci-0002dx-8b for submit@debbugs.gnu.org; Mon, 02 Apr 2018 19:49:36 -0400 Original-Received: from mail-io0-f175.google.com ([209.85.223.175]:34165) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1f39Cg-0002dg-Kh; Mon, 02 Apr 2018 19:49:35 -0400 Original-Received: by mail-io0-f175.google.com with SMTP id d6so17833204iog.1; Mon, 02 Apr 2018 16:49:34 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20161025; h=from:to:cc:subject:references:date:in-reply-to:message-id :user-agent:mime-version; bh=4pLFMytr5H7a4OeTFT5x4NyuWTONKRar5imzU/FCo8s=; b=FQNjkbVpDeiUrMZlM9ORv4joECASofuOeumbpRmhArRFIhxQrTedjVKyNtsF9e+s6l SW39QM/B69qxLP+GGwAYyhWjNIdCXA1lEd31cVyQV83SoWiqtbXdCX8zp4xbOiInHuKj RPzE3sLKPrQjOeie1t2+V4m8voEkRlmwzh1xqmjH5aqqP7D2R4ZGudljzHmrxRfoRRFU H3Gro/a01O2r86QO4StVZlKwws+Z0ysXiLQJOvfxTLg+FEaCUNGyi8u3qVHHUSqlHoHC jD5789Drc3/IlWvj2D/eTozSIsuMWNws/+76/5yeEQ5AbW4U278XSxG66AXVsIhSfpT6 Ho2Q== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:from:to:cc:subject:references:date:in-reply-to :message-id:user-agent:mime-version; bh=4pLFMytr5H7a4OeTFT5x4NyuWTONKRar5imzU/FCo8s=; b=EE88frJ6AsqW+hocI9IfrFLwaxSrlORyQJhXF3djlrbEu24VYVRpbOZ9pjuNctz6bp DtakIZj3p5jVyij3usgYAlnBSY3NEC+lSQx8/eNJpfJKJ9znpJmWeyOJwJSfrJUzoG4A Gkmo+jbj79SJwjpnCSwk3bKnBODUyLLftgYZ3y+bmEreeEF/cpTlYjeRVtvQXUx/kMso i3wqhCz6a1NAvhxzwDIPioZGzvGkN0XODsE44BtbPf5tzjk9R2DMr9K3v6u8R/Is+hDv R1Wj66PYRiZas+URN2+qVqiK3o2vzTVW1ZU5tgHLLh7KOZ/ECVwOtfFOUNusPmiW+mrS j4Vg== X-Gm-Message-State: AElRT7GwI+byqxvzaRh+wAkcbziRGpFvBkewZ2vSjV2IsT6cZtobYFQt QOlPX0rBtH7nQ+3OYXD0qi0WfQ== X-Google-Smtp-Source: AIpwx48bBD0NplbhIe52gLmgNitH3up4zupRponwqzUb7h1Xf534cF2OiQInm5B24EHq07IMmw/GwQ== X-Received: by 10.107.58.134 with SMTP id h128mr10170604ioa.299.1522712968819; Mon, 02 Apr 2018 16:49:28 -0700 (PDT) Original-Received: from zebian (cbl-45-2-119-34.yyz.frontiernetworks.ca. [45.2.119.34]) by smtp.googlemail.com with ESMTPSA id z64sm723590ioi.51.2018.04.02.16.49.27 (version=TLS1_2 cipher=ECDHE-RSA-CHACHA20-POLY1305 bits=256/256); Mon, 02 Apr 2018 16:49:28 -0700 (PDT) In-Reply-To: <87wp00ixfx.fsf@users.sourceforge.net> (Noam Postavsky's message of "Mon, 29 Jan 2018 08:52:50 -0500") X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.18 Precedence: list X-detected-operating-system: by eggs.gnu.org: GNU/Linux 2.2.x-3.x [generic] X-Received-From: 208.118.235.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" Xref: news.gmane.org gmane.emacs.bugs:144817 Archived-At: merge 15695 16019 quit > If I set process-connection-type to nil, then I get expected results > This problem is also talked about in [1] and [2]. > > [1]: http://nullprogram.com/blog/2018/01/17/ > [2]: http://nullprogram.com/blog/2014/02/06/#pseudo-terminals Actually, I don't think this bug is a problem of Emacs losing data after all, it's just that the shell does the 'echo baz' and then usually exits before the other echo commands get to run (when running with a pty, Emacs sends SIGHUP to all child process in the terminal). If I add a "; wait" to the shell command, then I get "baz\nbar\nfoo\n": 374 "baz\nfoo\nbar\n": 428 "foo\nbaz\nbar\n": 17 "bar\nfoo\nbaz\n": 1 which is as expected. I'm merging with #16019 which is about Emacs sending SIGHUP to all child processes of a pty subprocess.