GNU bug report logs -
#73905
guix shell changes default sigaction for SIGPIPE
Previous Next
Reported by: Tomas Volf <~@wolfsden.cz>
Date: Sun, 20 Oct 2024 11:27:01 UTC
Severity: normal
Tags: patch
Done: Ludovic Courtès <ludo <at> gnu.org>
Bug is archived. No further changes may be made.
To add a comment to this bug, you must first unarchive it, by sending
a message to control AT debbugs.gnu.org, with unarchive 73905 in the body.
You can then email your comments to 73905 AT debbugs.gnu.org in the normal way.
Toggle the display of automated, internal messages from the tracker.
Report forwarded
to
bug-guix <at> gnu.org
:
bug#73905
; Package
guix
.
(Sun, 20 Oct 2024 11:27:01 GMT)
Full text and
rfc822 format available.
Acknowledgement sent
to
Tomas Volf <~@wolfsden.cz>
:
New bug report received and forwarded. Copy sent to
bug-guix <at> gnu.org
.
(Sun, 20 Oct 2024 11:27:01 GMT)
Full text and
rfc822 format available.
Message #5 received at submit <at> debbugs.gnu.org (full text, mbox):
[Message part 1 (text/plain, inline)]
Guix shell changes the default handler for SIGPIPE for the command it
runs. Can be demonstrated using the following:
--8<---------------cut here---------------start------------->8---
$ guix shell guile -- guile -c '(pk (sigaction SIGPIPE))'
;;; ((1 . 0))
$ guile -c '(pk (sigaction SIGPIPE))'
;;; ((0 . 0))
--8<---------------cut here---------------end--------------->8---
Have a nice day,
Tomas Volf
--
There are only two hard things in Computer Science:
cache invalidation, naming things and off-by-one errors.
[signature.asc (application/pgp-signature, inline)]
Information forwarded
to
guix <at> cbaines.net, dev <at> jpoiret.xyz, ludo <at> gnu.org, othacehe <at> gnu.org, zimon.toutoune <at> gmail.com, me <at> tobias.gr, bug-guix <at> gnu.org
:
bug#73905
; Package
guix
.
(Sun, 20 Oct 2024 14:45:01 GMT)
Full text and
rfc822 format available.
Message #8 received at 73905 <at> debbugs.gnu.org (full text, mbox):
Code in `ui.scm' in `initialize-guix' procedure changes the handling of
SIGPIPE to SIG_IGN. So restore the handling to SIG_DFL so that process
executed will have the usual action. Technically we should record what the
handling was, and restore it to the previous value, but that would be much
more invasive change.
Always setting it to SIG_DFL is at least less surprising than always setting
to SIG_IGN.
* guix/scripts/environment.scm (launch-environment): Restore default action
for SIGPIPE.
Change-Id: Ifabae1d3e71aa44e63078cea5bd3824b8f61ba14
---
guix/scripts/environment.scm | 2 ++
1 file changed, 2 insertions(+)
diff --git a/guix/scripts/environment.scm b/guix/scripts/environment.scm
index a219b2ac89..79eb7f3f30 100644
--- a/guix/scripts/environment.scm
+++ b/guix/scripts/environment.scm
@@ -499,6 +499,8 @@ (define* (launch-environment command profile manifest
;; Properly handle SIGINT, so pressing C-c in an interactive terminal
;; application works.
(sigaction SIGINT SIG_DFL)
+ ;; Restore original action for SIGPIPE.
+ (sigaction SIGPIPE SIG_DFL)
(load-profile profile manifest
#:pure? pure? #:white-list-regexps white-list)
--
2.46.0
Added tag(s) patch.
Request was from
Tomas Volf <~@wolfsden.cz>
to
control <at> debbugs.gnu.org
.
(Sun, 20 Oct 2024 14:53:02 GMT)
Full text and
rfc822 format available.
Information forwarded
to
guix <at> cbaines.net, dev <at> jpoiret.xyz, ludo <at> gnu.org, othacehe <at> gnu.org, zimon.toutoune <at> gmail.com, me <at> tobias.gr, bug-guix <at> gnu.org
:
bug#73905
; Package
guix
.
(Fri, 02 May 2025 17:00:02 GMT)
Full text and
rfc822 format available.
Message #13 received at 73905 <at> debbugs.gnu.org (full text, mbox):
Code in `ui.scm' in `initialize-guix' procedure changes the handling of
SIGPIPE to SIG_IGN. So restore the handling to SIG_DFL so that process
executed will have the usual action. Technically we should record what the
handling was, and restore it to the previous value, but that would be much
more invasive change.
Always setting it to SIG_DFL is at least less surprising than always setting
to SIG_IGN.
* guix/scripts/environment.scm (launch-environment): Restore default action
for SIGPIPE.
Change-Id: Ifabae1d3e71aa44e63078cea5bd3824b8f61ba14
---
guix/scripts/environment.scm | 2 ++
1 file changed, 2 insertions(+)
diff --git a/guix/scripts/environment.scm b/guix/scripts/environment.scm
index 648a497743..7185c3ebd0 100644
--- a/guix/scripts/environment.scm
+++ b/guix/scripts/environment.scm
@@ -506,6 +506,8 @@ (define* (launch-environment command profile manifest
;; Properly handle SIGINT, so pressing C-c in an interactive terminal
;; application works.
(sigaction SIGINT SIG_DFL)
+ ;; Restore original action for SIGPIPE.
+ (sigaction SIGPIPE SIG_DFL)
(load-profile profile manifest
#:pure? pure? #:white-list-regexps white-list)
--
2.49.0
Reply sent
to
Ludovic Courtès <ludo <at> gnu.org>
:
You have taken responsibility.
(Mon, 05 May 2025 15:35:01 GMT)
Full text and
rfc822 format available.
Notification sent
to
Tomas Volf <~@wolfsden.cz>
:
bug acknowledged by developer.
(Mon, 05 May 2025 15:35:02 GMT)
Full text and
rfc822 format available.
Message #18 received at 73905-done <at> debbugs.gnu.org (full text, mbox):
Tomas Volf <~@wolfsden.cz> writes:
> Code in `ui.scm' in `initialize-guix' procedure changes the handling of
> SIGPIPE to SIG_IGN. So restore the handling to SIG_DFL so that process
> executed will have the usual action. Technically we should record what the
> handling was, and restore it to the previous value, but that would be much
> more invasive change.
>
> Always setting it to SIG_DFL is at least less surprising than always setting
> to SIG_IGN.
>
> * guix/scripts/environment.scm (launch-environment): Restore default action
> for SIGPIPE.
>
> Change-Id: Ifabae1d3e71aa44e63078cea5bd3824b8f61ba14
Applied, thanks!
bug archived.
Request was from
Debbugs Internal Request <help-debbugs <at> gnu.org>
to
internal_control <at> debbugs.gnu.org
.
(Tue, 03 Jun 2025 11:24:19 GMT)
Full text and
rfc822 format available.
This bug report was last modified 28 days ago.
Previous Next
GNU bug tracking system
Copyright (C) 1999 Darren O. Benham,
1997,2003 nCipher Corporation Ltd,
1994-97 Ian Jackson.