GNU bug report logs - #21972
24.5; Running 'bash -i -c' via shell-command hangs on FreeBSD

Previous Next

Package: emacs;

Reported by: Davor Cubranic <davor.cubranic <at> alumni.cs.ubc.ca>

Date: Sat, 21 Nov 2015 16:33:04 UTC

Severity: normal

Found in version 24.5

Done: Stefan Kangas <stefan <at> marxist.se>

Bug is archived. No further changes may be made.

Full log


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

From: Stefan Kangas <stefan <at> marxist.se>
To: Davor Cubranic <davor.cubranic <at> alumni.cs.ubc.ca>
Cc: 21972 <at> debbugs.gnu.org
Subject: Re: bug#21972: 24.5;
 Running 'bash -i -c' via shell-command hangs on FreeBSD
Date: Mon, 14 Oct 2019 21:55:22 +0200
Davor Cubranic <davor.cubranic <at> alumni.cs.ubc.ca> writes:

> On FreeBSD, running:
>
>   M-x shell-command
>   /usr/local/bin/bash -i -c "echo hello"

On GNU/Linux, the above gives me:

bash: cannot set terminal process group (-1): Inappropriate ioctl for device
bash: no job control in this shell
hello

> hangs until you press C-g (twice). I can see the bash process running at
> 100% via `top` until C-g kills it.
>
> Adding `--norc --noprofile` to the command still hangs, so it's not
> anything about the shell initialization files. The `-i` option is the
> key: without it, everything works fine.
>
> Running the same command via `async-shell-command` does not hang: Bash
> outputs "hello" in the "*Async Shell Command*" buffer and exits.
>
> Both Emacs and Bash are standard FreeBSD 10 binary packages installed
> via `pkg`. (emacs24-24.5_1,3 and bash-4.3.42, respectively).

If bash hangs, shouldn't that be reported as a bug in bash instead?
Or should Emacs somehow do better with a hanging process?

Best regards,
Stefan Kangas




This bug report was last modified 5 years and 222 days ago.

Previous Next


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