[BUG] Assertion error when EXIT signal trapped
Reported by eljay | May 3rd, 2008 @ 01:28 PM | in 1.0 preview
The Ruby specific "EXIT" signal (value = 0) is not trapped correctly because of an assertion in line ./shotgun/external_libs/libev/ev.c (see stack trace below)
You can use the attached 3 line Ruby file to test this. Run the program and Hit CTRL-C when invited to.
rubinius: ev.c:1871: ev_signal_start: Assertion `("ev_signal_start called with illegal signal number", w->signum > 0)' failed.
An error has occured: Software abort (SIGABRT) (6)
Ruby backtrace:
0xb73e0db4 Class#trap+275 in kernel/core/signal.rb:61
0xb7a11760 Kernel#trap+53 in kernel/core/kernel.rb:337
0xb73e0cd4 #__script__+20 in /tmp/test_sig.rb:1
0xb7a11810 CompiledMethod#as_script+80 in kernel/core/compiled_method.rb:332
0xb78ec6d0 Class#single_load+460 in kernel/core/compile.rb:247
0xb7a118c0 Class#load_from_extension+222 in kernel/core/compile.rb:324
0xb78ecce4 #__script__+1325 in kernel/loader.rb:203
You should probably introduce some specific code in ev.c to handle the case signal=0 and run a function like sigexit that terminates the current thread. My $.02 contribution.
Comments and changes to this ticket
-
Ryan Davis May 6th, 2008 @ 12:43 AM
- → Assigned user changed from to Evan Phoenix
-
Evan Phoenix June 26th, 2008 @ 10:51 AM
- → Tag changed from to exit signal trap
- → State changed from new to resolved
This has been fixed. EXIT isn't a real signal, and thats why we had this problem. It's handled as a special case now, properly.
Please Login or create a free account to add a new comment.
You can update this ticket by sending an email to from your email client. (help)
Create your profile
Help contribute to this project by taking a few moments to create your personal profile. Create your profile »
