lib/rubydns.rb in rubydns-0.8.1 vs lib/rubydns.rb in rubydns-0.8.4

- old
+ new

@@ -29,9 +29,13 @@ # Run a server with the given rules. def self.run_server (options = {}, &block) server = RubyDNS::RuleBasedServer.new(&block) EventMachine.run do + trap("INT") do + EventMachine::stop + end + server.run(options) end server.fire(:stop) end