GNU bug report logs - #48565
Using move->fdes to move stdin to 9 + interrupt (C-c) exits guile

Previous Next

Package: guile;

Reported by: Maxime Devos <maximedevos <at> telenet.be>

Date: Fri, 21 May 2021 13:01:02 UTC

Severity: normal

To reply to this bug, email your comments to 48565 AT debbugs.gnu.org.

Toggle the display of automated, internal messages from the tracker.

View this report as an mbox folder, status mbox, maintainer mbox


Report forwarded to bug-guile <at> gnu.org:
bug#48565; Package guile. (Fri, 21 May 2021 13:01:02 GMT) Full text and rfc822 format available.

Acknowledgement sent to Maxime Devos <maximedevos <at> telenet.be>:
New bug report received and forwarded. Copy sent to bug-guile <at> gnu.org. (Fri, 21 May 2021 13:01:02 GMT) Full text and rfc822 format available.

Message #5 received at submit <at> debbugs.gnu.org (full text, mbox):

From: Maxime Devos <maximedevos <at> telenet.be>
To: bug-guile <at> gnu.org
Subject: Using move->fdes to move stdin to 9 +  interrupt (C-c) exits guile
Date: Fri, 21 May 2021 14:59:44 +0200
[Message part 1 (text/plain, inline)]
user <at> hostname ~$ guile
GNU Guile 3.0.5
Copyright (C) 1995-2021 Free Software Foundation, Inc.

Guile comes with ABSOLUTELY NO WARRANTY; for details type `,show w'.
This program is free software, and you are welcome to redistribute it
under certain conditions; type `,show c' for details.

Enter `,help' for help.
scheme@(guile-user)> blabla [C-c C-c]
While reading expression:
User interrupt
scheme@(guile-user)> (move->fdes (fdes->inport 0) 9)
$1 = #<input: file /dev/pts/8>
scheme@(guile-user)> [C-c C-C]
user <at> hostname ~$

What I expected:
While reading expression:
User interrupt

Your file descriptor may vary.

My suspicion: look at libguile/scmsigs.c (start_signal_delivery_thread),
in particular:

  if (pipe2 (signal_pipe, O_CLOEXEC) != 0)
    scm_syserror (NULL);

signal_pipe[0] and signal_pipe[1] don't seem to be added to the
port table, so primitive-move->fdes does not know about the signal pipes
and will silently overwrite them.

Greetings,
Maxime
[signature.asc (application/pgp-signature, inline)]

This bug report was last modified 3 years and 187 days ago.

Previous Next


GNU bug tracking system
Copyright (C) 1999 Darren O. Benham, 1997,2003 nCipher Corporation Ltd, 1994-97 Ian Jackson.