[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Re: [BUG] Bash not reacting to Ctrl-C
From: |
Chet Ramey |
Subject: |
Re: [BUG] Bash not reacting to Ctrl-C |
Date: |
Sun, 06 Mar 2011 16:40:30 -0500 |
User-agent: |
Mozilla/5.0 (Macintosh; U; Intel Mac OS X 10.6; en-US; rv:1.9.2.13) Gecko/20101207 Lightning/1.0b2 Thunderbird/3.1.7 |
On 3/1/11 1:28 AM, Linus Torvalds wrote:
> A real interactive program that uses ^C (like an editor) isn't
> actually ever going to see a SIGINT _at_all_, since it will set the
> tty state to -isig, and actually read the ^C as the character '\003'
> rather than have any SIGINT issues). I dunno.
I will look at the rest of this, but in the case of GNU emacs, for
instance, the above is not true. Emacs either keeps isig and makes
^G the interrupt character, or sets -isig and sends SIGINT to its own
pgrp when it reads ^G. Regardless, an enclosing script gets a SIGINT
when you use ^G in GNU emacs.
Chet
--
``The lyf so short, the craft so long to lerne.'' - Chaucer
``Ars longa, vita brevis'' - Hippocrates
Chet Ramey, ITS, CWRU chet@case.edu http://cnswww.cns.cwru.edu/~chet/
Re: [BUG] Bash not reacting to Ctrl-C, Oleg Nesterov, 2011/03/07