Re: [PATCH] x86_64: fix delayed signals

Andi Kleen
2008-07-13T09:38:24Z

Linus Torvalds wrote:
>
> On Sat, 12 Jul 2008, Andi Kleen wrote:
>> Linus, the fact that is not explained by your theory is why
>> Ctrl-Z+kill works but Ctrl-C doesn't.
>
> Umm. Read the reports more carefully. Many of the complaints are about ^Z
> too.

At least the original report was about Ctrl-C only versus Ctrl-Z.

I see the problem regularly myself that Ctrl-C doesn't work,
but Ctrl-Z+kill does (although I unfortunately cannot
reproduce it on demand). But it was with programs who shouldn't catch Ctrl-C,
like find. I confirmed with ltrace that at least my version of find doesn't
catch any signals.

Take the original report for example:

http://marc.info/?l=linux-kernel&m=121464952615807&w=2

It also had trouble interrupting find:

$ find / >/dev/null
find: `/boot/lost+found': Permission denied
^C^C^C^C^C^C^C^C^C^C^C^C^C^C^C^C^C^C^C^C^C^C^C^C^C^C^C^C^C^C^C

but Ctrl-Z+kill worked immediately.

> The reason? It's quite common to catch ^C in order to do cleanup.

Yes I understand that, but I don't think it's the case here.

I'm afraid it's more a "has a simple explanation that is wrong"
case here.

Or we might be talking about multiple different bugs.

-Andi