Python 2.3.3 signals, threads & extensions: signal handling problem[Resolved]

Python 2.3.3 signals, threads & extensions: signal handling problem[Resolved]

Post by Holger Jou » Wed, 09 Jun 2004 19:07:47


Stupid me: This is what I found in the script code:
print '*** Note: you need to kill this with SIGKILL ***'
Testing the code again I see the same behaviour for python 1.5.2 and python
2.3.3
(the signal handler, installed in the main thread, not getting the signals
*most of the time*).
Seems like it was one of those days the other time.
Thank you to Andrew and fishboy.
Cheers
Holger

Der Inhalt dieser E-Mail ist vertraulich. Falls Sie nicht der angegebene
Empfger sind oder falls diese E-Mail irrtlich an Sie adressiert wurde,
verstdigen Sie bitte den Absender sofort und lchen Sie die E-Mail
sodann. Das unerlaubte Kopieren sowie die unbefugte ermittlung sind nicht
gestattet. Die Sicherheit von ermittlungen per E-Mail kann nicht
garantiert werden. Falls Sie eine Bestigung wschen, fordern Sie bitte
den Inhalt der E-Mail als Hardcopy an.

The contents of this e-mail are confidential. If you are not the named
addressee or if this transmission has been addressed to you in error,
please notify the sender immediately and then delete this e-mail. Any
unauthorized copying and transmission is forbidden. E-Mail transmission
cannot be guaranteed to be secure. If verification is required, please
request a hard copy version.
 
 
 

1. POSIX signal handling versus traditional signal handling

2. [PATCH] Fix i386 signal handling of NODEFER, should not affect sa_mask (was: Signal handling possibly wrong)


Hmm, I think you want this patch. You still need to check the return of
setting up the frames.

-- Steve

Signed-off-by: Steven Rostedt < XXXX@XXXXX.COM >

--- linux-2.6.13-rc6-git1/arch/i386/kernel/signal.c.orig 2005-08-09 16:54:36.000000000 -0400
+++ linux-2.6.13-rc6-git1/arch/i386/kernel/signal.c 2005-08-09 16:55:24.000000000 -0400
@@ -577,10 +577,11 @@ handle_signal(unsigned long sig, siginfo
else
ret = setup_frame(sig, ka, oldset, regs);

- if (ret && !(ka->sa.sa_flags & SA_NODEFER)) {
+ if (ret) {
spin_lock_irq(¤t->sighand->siglock);
sigorsets(¤t->blocked,¤t->blocked,&ka->sa.sa_mask);
- sigaddset(¤t->blocked,sig);
+ if (!(ka->sa.sa_flags & SA_NODEFER))
+ sigaddset(¤t->blocked,sig);
recalc_sigpending();
spin_unlock_irq(¤t->sighand->siglock);
}


-
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to XXXX@XXXXX.COM
More majordomo info at http://www.yqcomputer.com/
Please read the FAQ at http://www.yqcomputer.com/

3. POSIX signal handling versus traditional signal handling

4. [PATCH] Fix i386 signal handling of NODEFER, should not affect sa_mask (was: Signal handling possibly wrong)

5. Signal Extension (package Signal)

6. clarification on thread-directed signals v. signal queueing

7. thread behaviour during signal handling

8. signal handling with multiple threads

9. [RFC][PATCH] Kernel thread signal handling.

10. posix threads and Signal handling

11. how to safely cancel a synchronous signal handling thread?

12. Two-threaded program handling signals...

13. Signal handling in multi-threaded applications.

14. Thread finished but its handle not signaled?