Feature Requests: Browse | Submit New | Admin
Instead of automatically redirecting STDOUT and STDERR to NUL, allow the user to pass a file name as an argument to Daemon.new. If present, STDOUT and STDERR will then be redirected to that handle in append mode. It would be up to the user to properly close the handle in the service_stop method. Dan (me)
Add A Comment:
Date: 2009-06-30 16:32 Sender: Daniel Berger Come to think of it, we probably shouldn't be closing stdin if it's an interactive service. Dan (me)
Date: 2009-06-30 16:03 Sender: Daniel Berger Actually, maybe it would be easier to allow arguments to the mainloop method, with options for each handle like so: MyDaemon.mainloop( :stderr => "C:/errors.log", :stdout => "C:/output.log" :stdin => nil ) I think we could automatically close the handles in the service_stop method, too. Just look for the appropriate instance variables and see if they're set. Dan (me)