suspend/fg excitement in *shell*

View: New views
11 Messages — Rating Filter:   Alert me  

suspend/fg excitement in *shell*

by jidanni :: Rate this Message:

Reply to Author | View Threaded | Show Only this Message

I notice in the *shell* buffer, suspend/fg acts funny.

sh-3.1$ su
Password:
root@jidanni1:/tmp# suspend

[1]+  Stopped(SIGSTOP)        su
sh-3.1$ fg
su
root@jidanni1:/tmp# exit <--I did not type "exit". God did for me
apparently.

I also notice that if I do the above experiment without doing
# mv .bash* /somewhere/other/than/root's/home/dir
first, apparently the .bash_history file starts getting munched, with
all kinds of wacko commands getting executed or something with
multiple kill(1)'s needed to stamp out the frenzy.

In GNU Emacs 22.1.1 (i486-pc-linux-gnu, X toolkit, Xaw3d scroll bars)
 of 2007-07-07 on raven, modified by Debian


_______________________________________________
emacs-pretest-bug mailing list
emacs-pretest-bug@...
http://lists.gnu.org/mailman/listinfo/emacs-pretest-bug

Re: suspend/fg excitement in *shell*

by Glenn Morris-3 :: Rate this Message:

Reply to Author | View Threaded | Show Only this Message

Dan Jacobson wrote:

> I notice in the *shell* buffer, suspend/fg acts funny.

I cannot reproduce this. If you want this investigating, please
provide a clear recipe showing the minimum emacs and shell
configurations needed to produce the problem.


_______________________________________________
emacs-pretest-bug mailing list
emacs-pretest-bug@...
http://lists.gnu.org/mailman/listinfo/emacs-pretest-bug

Re: suspend/fg excitement in *shell*

by jidanni :: Rate this Message:

Reply to Author | View Threaded | Show Only this Message

GM> I cannot reproduce this.

At least you perhaps can reproduce in an emacs *shell* buffer:
---------------
jidanni@jidanni2:~$ su
Password:
root@jidanni2:/tmp# suspend

[1]+  Stopped                 su
jidanni@jidanni2:~$ fg
su
root@jidanni2:/tmp# exit <---I did not type "exit"!
jidanni@jidanni2:~$ jobs
jidanni@jidanni2:~$
----------------
Whereas in xterm one gets
...$ fg
su
root@jidanni2:/tmp#
----------------
i.e., without having the "exit" magically typed in for us ending the su session.


_______________________________________________
emacs-pretest-bug mailing list
emacs-pretest-bug@...
http://lists.gnu.org/mailman/listinfo/emacs-pretest-bug

Re: suspend/fg excitement in *shell*

by Sven Joachim :: Rate this Message:

Reply to Author | View Threaded | Show Only this Message

jidanni@... writes:

> At least you perhaps can reproduce in an emacs *shell* buffer:
> ---------------
> jidanni@jidanni2:~$ su
> Password:
> root@jidanni2:/tmp# suspend
>
> [1]+  Stopped                 su
> jidanni@jidanni2:~$ fg
> su
> root@jidanni2:/tmp# exit <---I did not type "exit"!

I can reproduce this.  Actually, the shell gets an EOF from somewhere,
since on my system I get the message "Use 'exit' to leave the shell."
I have IGNOREEOF=2 in /root/.bashrc.

Regards,
        Sven


_______________________________________________
emacs-pretest-bug mailing list
emacs-pretest-bug@...
http://lists.gnu.org/mailman/listinfo/emacs-pretest-bug

Re: suspend/fg excitement in *shell*

by jidanni :: Rate this Message:

Reply to Author | View Threaded | Show Only this Message

SJ> I have IGNOREEOF=2 in /root/.bashrc.

It turns out with greater IGNOREEOF's, and more "fg"'s, the sucker
heads straight for the HISTFILE where it proceeds to execute all the
commands there faster than you can kill(1) them. "A monster has taken
over my '*shell*' buffer and is sending root ^P^O&'s or whatever it
takes to replay my HISTORY file faster than I can swat all it is
spawning!" Here I fool it with HISTFILE=/dev/null:

02:58 1 tmp$ su
Password:
root@jidanni2:/tmp# IGNOREEOF=11 HISTFILE=/dev/null
root@jidanni2:/tmp# suspend

[1]+  Stopped                 su
02:59 147 tmp$ fg
su
root@jidanni2:/tmp# Use "exit" to leave the shell.
root@jidanni2:/tmp#
[1]+  Stopped                 su
02:59 147 tmp$ fg
su
root@jidanni2:/tmp# bash: =/dev/null: No such file or directory
root@jidanni2:/tmp# bash: syntax error near unexpected token `('
root@jidanni2:/tmp# [1] 15423
root@jidanni2:/tmp# bash:\350\2600\322: command not found
root@jidanni2:/tmp#


_______________________________________________
emacs-pretest-bug mailing list
emacs-pretest-bug@...
http://lists.gnu.org/mailman/listinfo/emacs-pretest-bug

Re: suspend/fg excitement in *shell*

by jidanni :: Rate this Message:

Reply to Author | View Threaded | Show Only this Message

Also exiting an emacs that contains such shells still alive (merely
sitting at their prompts), sends the signal to them to get wacko.


_______________________________________________
emacs-pretest-bug mailing list
emacs-pretest-bug@...
http://lists.gnu.org/mailman/listinfo/emacs-pretest-bug

Re: suspend/fg excitement in *shell*

by Richard Stallman :: Rate this Message:

Reply to Author | View Threaded | Show Only this Message

    Also exiting an emacs that contains such shells still alive (merely
    sitting at their prompts), sends the signal to them to get wacko.

That sounds like a shell bug to me.

Does it happen with Emacs 21.4 too?


_______________________________________________
emacs-pretest-bug mailing list
emacs-pretest-bug@...
http://lists.gnu.org/mailman/listinfo/emacs-pretest-bug

Re: suspend/fg excitement in *shell*

by Sven Joachim :: Rate this Message:

Reply to Author | View Threaded | Show Only this Message

Richard Stallman <rms@...> writes:

>     Also exiting an emacs that contains such shells still alive (merely
>     sitting at their prompts), sends the signal to them to get wacko.
>
> That sounds like a shell bug to me.
>
> Does it happen with Emacs 21.4 too?

Yes, I can reproduce this with Emacs 21.4.


_______________________________________________
emacs-pretest-bug mailing list
emacs-pretest-bug@...
http://lists.gnu.org/mailman/listinfo/emacs-pretest-bug

Re: suspend/fg excitement in *shell*

by Glenn Morris-3 :: Rate this Message:

Reply to Author | View Threaded | Show Only this Message

jidanni@... wrote:

> GM> I cannot reproduce this.
>
> At least you perhaps can reproduce in an emacs *shell* buffer:

No, I can't. Surprisingly, you just repeating most of what you said
the first time word for word has not helped me to do so.


_______________________________________________
emacs-pretest-bug mailing list
emacs-pretest-bug@...
http://lists.gnu.org/mailman/listinfo/emacs-pretest-bug

Re: suspend/fg excitement in *shell*

by Glenn Morris-3 :: Rate this Message:

Reply to Author | View Threaded | Show Only this Message

Sven Joachim wrote:

> Yes, I can reproduce this with Emacs 21.4.

How about outside Emacs?


_______________________________________________
emacs-pretest-bug mailing list
emacs-pretest-bug@...
http://lists.gnu.org/mailman/listinfo/emacs-pretest-bug

Re: suspend/fg excitement in *shell*

by Sven Joachim :: Rate this Message:

Reply to Author | View Threaded | Show Only this Message

Glenn Morris <rgm@...> writes:

> Sven Joachim wrote:
>
>> Yes, I can reproduce this with Emacs 21.4.
>
> How about outside Emacs?

Outside Emacs suspending a su'ed bash works fine.


_______________________________________________
emacs-pretest-bug mailing list
emacs-pretest-bug@...
http://lists.gnu.org/mailman/listinfo/emacs-pretest-bug