On Thu, 2 Jun 2005 wmwilson01 / gmail.com wrote: untested, but i think you may have to do something like > I know I must be doing something dumb here, but I can't figure out > what, and I'm about to give up. I'm setting a trap("HUP") to call a > couple of functions (basically to re-read a config). The first time > running a "kill -HUP" on the process works fine, but the second time it > exits with a "hangup". If I modify the trap to look like: > > trap("HUP") { > trap("HUP", "IGNORE") > fun1 > fun2 > } > > It doesn't hangup, but only the first "kill -HUP" actually re-reads the > configuration. maybe something like harp:~ > cat a.rb hup_proc = lambda {|*a| p 42 trap 'HUP', hup_proc } trap 'HUP', hup_proc 3.times{ Process::kill 'HUP', $$ } harp:~ > ruby a.rb 42 42 42 hth. -a -- =============================================================================== | email :: ara [dot] t [dot] howard [at] noaa [dot] gov | phone :: 303.497.6469 | My religion is very simple. My religion is kindness. | --Tenzin Gyatso ===============================================================================