summary refs log tree commit homepage
diff options
context:
space:
mode:
authorEric Wong <normalperson@yhbt.net>2009-09-04 01:57:06 -0700
committerEric Wong <normalperson@yhbt.net>2009-09-04 01:57:06 -0700
commitd0c9f1aeb94397883197dd8ee0c600d3f18f9ac9 (patch)
tree90211102cc9406841c31691103851033dce2c279
parentd4fd801ceebf56fe9204a3b2829138fb4c433d39 (diff)
Avoid potential issues that can arise from logging any weird
characters that may not be supported in the current encoding.
-rw-r--r--lib/unicorn.rb2
1 files changed, 1 insertions, 1 deletions
diff --git a/lib/unicorn.rb b/lib/unicorn.rb
index 88391f6..0916891 100644
--- a/lib/unicorn.rb
+++ b/lib/unicorn.rb
@@ -630,7 +630,7 @@ module Unicorn
     end
 
     def redirect_io(io, path)
-      File.open(path, 'a') { |fp| io.reopen(fp) } if path
+      File.open(path, 'ab') { |fp| io.reopen(fp) } if path
       io.sync = true
     end