From mboxrd@z Thu Jan 1 00:00:00 1970 Path: news.gmane.io!.POSTED.blaine.gmane.org!not-for-mail From: Ricardo Wurmus Newsgroups: gmane.lisp.guile.bugs Subject: bug#46403: SIGINT ignored when using system* Date: Tue, 09 Feb 2021 14:56:06 +0100 Message-ID: <87zh0dqr9l.fsf@elephly.net> Mime-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: quoted-printable Injection-Info: ciao.gmane.io; posting-host="blaine.gmane.org:116.202.254.214"; logging-data="28352"; mail-complaints-to="usenet@ciao.gmane.io" User-Agent: mu4e 1.4.14; emacs 27.1 To: 46403@debbugs.gnu.org Original-X-From: bug-guile-bounces+guile-bugs=m.gmane-mx.org@gnu.org Tue Feb 09 15:21:30 2021 Return-path: Envelope-to: guile-bugs@m.gmane-mx.org Original-Received: from lists.gnu.org ([209.51.188.17]) by ciao.gmane.io with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.92) (envelope-from ) id 1l9TtQ-0007DC-38 for guile-bugs@m.gmane-mx.org; Tue, 09 Feb 2021 15:21:28 +0100 Original-Received: from localhost ([::1]:35220 helo=lists1p.gnu.org) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1l9TtP-0006Kw-52 for guile-bugs@m.gmane-mx.org; Tue, 09 Feb 2021 09:21:27 -0500 Original-Received: from eggs.gnu.org ([2001:470:142:3::10]:42176) by lists.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1l9TVm-0000zm-Lr for bug-guile@gnu.org; Tue, 09 Feb 2021 08:57:02 -0500 Original-Received: from debbugs.gnu.org ([209.51.188.43]:41357) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_128_GCM_SHA256:128) (Exim 4.90_1) (envelope-from ) id 1l9TVm-0007qZ-CL for bug-guile@gnu.org; Tue, 09 Feb 2021 08:57:02 -0500 Original-Received: from Debian-debbugs by debbugs.gnu.org with local (Exim 4.84_2) (envelope-from ) id 1l9TVm-000148-8q for bug-guile@gnu.org; Tue, 09 Feb 2021 08:57:02 -0500 X-Loop: help-debbugs@gnu.org Resent-From: Ricardo Wurmus Original-Sender: "Debbugs-submit" Resent-CC: bug-guile@gnu.org Resent-Date: Tue, 09 Feb 2021 13:57:02 +0000 Resent-Message-ID: Resent-Sender: help-debbugs@gnu.org X-GNU-PR-Message: report 46403 X-GNU-PR-Package: guile X-Debbugs-Original-To: bug-guile@gnu.org Original-Received: via spool by submit@debbugs.gnu.org id=B.16128789804042 (code B ref -1); Tue, 09 Feb 2021 13:57:02 +0000 Original-Received: (at submit) by debbugs.gnu.org; 9 Feb 2021 13:56:20 +0000 Original-Received: from localhost ([127.0.0.1]:52901 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1l9TV6-000138-9I for submit@debbugs.gnu.org; Tue, 09 Feb 2021 08:56:20 -0500 Original-Received: from lists.gnu.org ([209.51.188.17]:41462) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1l9TV4-000130-BK for submit@debbugs.gnu.org; Tue, 09 Feb 2021 08:56:19 -0500 Original-Received: from eggs.gnu.org ([2001:470:142:3::10]:41922) by lists.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1l9TV3-0008VI-SC for bug-guile@gnu.org; Tue, 09 Feb 2021 08:56:17 -0500 Original-Received: from sender4-of-o51.zoho.com ([136.143.188.51]:21198) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1l9TV1-0007Vz-9p for bug-guile@gnu.org; Tue, 09 Feb 2021 08:56:17 -0500 ARC-Seal: i=1; a=rsa-sha256; t=1612878972; cv=none; d=zohomail.com; s=zohoarc; b=YRggALCU94EbdfvhROtESoWi+DcFNVcD08OnQLkofNSblfEG+Tg21/Xq+xkV0kVn+0wyJYIMdViwXMMHerfGqL21K70eKcpcq2OdZ+dNki2Ck0oFm09AZ5ZyLUpIFHQKHAwtHYLr52fQa9ABbYP5WBAzcdoZj94KytoeykGGDnQ= ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=zohomail.com; s=zohoarc; t=1612878972; h=Content-Type:Content-Transfer-Encoding:Date:From:MIME-Version:Message-ID:Subject:To; bh=7YTDHQM3+QuGblMMG8iprQ4+xLXhlN9yLkh/p2UVdxg=; b=bYUcVG0EasxZ99nPX6i4JNQ8fAQvi/a6Am+ADN5DfCUPWT7zWiOuqw9rlAILXU3yvKXR1QuKutiv2wP7INq9KHmsiLCNI1un0b3n0vCAMDURvtjyWBlBiOf9luONEwIGeeiFR0sS92uM6K/abKzAkVZv+/a9oJsjkYXvRbIt4Vs= ARC-Authentication-Results: i=1; mx.zohomail.com; dkim=pass header.i=elephly.net; spf=pass smtp.mailfrom=rekado@elephly.net; dmarc=pass header.from= header.from= DKIM-Signature: v=1; a=rsa-sha256; q=dns/txt; c=relaxed/relaxed; t=1612878972; s=zoho; d=elephly.net; i=rekado@elephly.net; h=From:To:Subject:Date:Message-ID:MIME-Version:Content-Type:Content-Transfer-Encoding; bh=7YTDHQM3+QuGblMMG8iprQ4+xLXhlN9yLkh/p2UVdxg=; b=U0ubVyqu376QwYfIJ6D9wIHej1iycRwAyGxpduE5V1pyU6oCi6wyVtgrxKf7FN+N ZgkioEO5uw47wOUTLBHqfnEIOptLoJTJIZ7KhSV2aNqxdOIeuj6tnsxFHU73NyL03An fbulAInmWgS/19TLs2dGwHwCGXSs65KTs+Qo1V1Y= Original-Received: from localhost (p54ad4a28.dip0.t-ipconnect.de [84.173.74.40]) by mx.zohomail.com with SMTPS id 161287896961138.62476504737833; Tue, 9 Feb 2021 05:56:09 -0800 (PST) X-URL: https://elephly.net X-PGP-Key: https://elephly.net/rekado.pubkey X-PGP-Fingerprint: BCA6 89B6 3655 3801 C3C6 2150 197A 5888 235F ACAC X-ZohoMailClient: External Received-SPF: pass client-ip=136.143.188.51; envelope-from=rekado@elephly.net; helo=sender4-of-o51.zoho.com X-Spam_score_int: -20 X-Spam_score: -2.1 X-Spam_bar: -- X-Spam_report: (-2.1 / 5.0 requ) BAYES_00=-1.9, DKIM_SIGNED=0.1, DKIM_VALID=-0.1, DKIM_VALID_AU=-0.1, DKIM_VALID_EF=-0.1, RCVD_IN_DNSWL_NONE=-0.0001, RCVD_IN_MSPIKE_H4=0.001, RCVD_IN_MSPIKE_WL=0.001, SPF_HELO_NONE=0.001, SPF_PASS=-0.001 autolearn=ham autolearn_force=no X-Spam_action: no action X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.18 Precedence: list X-BeenThere: bug-guile@gnu.org List-Id: "Bug reports for GUILE, GNU's Ubiquitous Extension Language" List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: bug-guile-bounces+guile-bugs=m.gmane-mx.org@gnu.org Original-Sender: "bug-guile" Xref: news.gmane.io gmane.lisp.guile.bugs:9981 Archived-At: I execute commands in a loop and wish to be able to interrupt the loop with SIGINT. Here=E2=80=99s the first attempt: guile -c \ '(for-each (lambda (n) (display n) (system* "sleep" "3")) (list 1 2 3 4))' At no point will this program be interrupted by SIGINT. Strace reveals that SIGINT is in fact received and the sleep is interrupted, but the wait is restarted immediately afterward. This program on the other hand *can* be interrupted at any point: guile -c \ '(for-each (lambda (n) (if (zero? (primitive-fork)) (begin (display n) (execlp "sleep" "sleep" "3")) (waitpid WAIT_ANY))) (list 1 2 3 4))' Is this by design? --=20 Ricardo