diff options
author | Eric Wong <normalperson@yhbt.net> | 2009-11-01 19:50:09 +0000 |
---|---|---|
committer | Eric Wong <normalperson@yhbt.net> | 2009-11-01 11:56:57 -0800 |
commit | 66a99327d91e3dd1974e615aa985759f984c5c64 (patch) | |
tree | 336f3ca3cfbdce4cee9bd22e56bc167154fd873c /lib/unicorn.rb | |
parent | 9326f16c7d6ae6b60bbc42a171f8c6b70c61bc4f (diff) | |
download | unicorn-66a99327d91e3dd1974e615aa985759f984c5c64.tar.gz |
Even if START_CTX[:cwd] is pointing to another directory, avoid overriding the user's decision to Dir.chdir if they do it in either the Unicorn config file or the config.ru.
Diffstat (limited to 'lib/unicorn.rb')
-rw-r--r-- | lib/unicorn.rb | 7 |
1 files changed, 0 insertions, 7 deletions
diff --git a/lib/unicorn.rb b/lib/unicorn.rb index 8e3bf32..94be9d2 100644 --- a/lib/unicorn.rb +++ b/lib/unicorn.rb @@ -490,13 +490,6 @@ module Unicorn def spawn_missing_workers (0...worker_processes).each do |worker_nr| WORKERS.values.include?(worker_nr) and next - begin - Dir.chdir(START_CTX[:cwd]) - rescue Errno::ENOENT => err - logger.fatal "#{err.inspect} (#{START_CTX[:cwd]})" - SIG_QUEUE << :QUIT # forcibly emulate SIGQUIT - return - end worker = Worker.new(worker_nr, Unicorn::Util.tmpio) before_fork.call(self, worker) WORKERS[fork { worker_loop(worker) }] = worker |