FastCGI handler ignores unsupported signals like USR2 on Windows [Grzegorz Derebecki]

git-svn-id: http://svn-commit.rubyonrails.org/rails/trunk@8132 5ecf4fe2-1ee6-0310-87b1-e25e094e27de
This commit is contained in:
Jeremy Kemper 2007-11-13 00:54:57 +00:00
parent 578c7a18e4
commit 78fb61a1fa
2 changed files with 8 additions and 1 deletions

View File

@ -1,5 +1,7 @@
*SVN*
* FastCGI handler ignores unsupported signals like USR2 on Windows. [Grzegorz Derebecki]
* Only load ActionMailer::TestCase if ActionMailer is loaded. Closes #10137 [defunkt]
* Fixed that db:reset would use migrations instead of loading db/schema.rb [DHH]

View File

@ -133,7 +133,12 @@ class RailsFCGIHandler
def install_signal_handler(signal, handler = nil)
if SIGNALS.include?(signal) && self.class.method_defined?(name = "#{SIGNALS[signal]}_handler")
handler ||= method(name).to_proc
trap(signal, handler)
begin
trap(signal, handler)
rescue ArgumentError
dispatcher_log :warn, "Ignoring unsupported signal #{signal}."
end
else
dispatcher_log :warn, "Ignoring unsupported signal #{signal}."
end