From 86e4849c08da3c5917844ce52782515731ef8df1 Mon Sep 17 00:00:00 2001 From: Eric Wong Date: Thu, 23 Apr 2009 18:57:46 -0700 Subject: Get rid of UNICORN_TMP_BASE constant It was just a waste of space and would've caused line wrapping. This reinstates the "unicorn" prefix when we create tempfiles, too. --- lib/unicorn/const.rb | 2 -- lib/unicorn/http_request.rb | 2 +- 2 files changed, 1 insertion(+), 3 deletions(-) diff --git a/lib/unicorn/const.rb b/lib/unicorn/const.rb index ea9312d..c05d333 100644 --- a/lib/unicorn/const.rb +++ b/lib/unicorn/const.rb @@ -58,8 +58,6 @@ module Unicorn UNICORN_VERSION="0.5.3".freeze - UNICORN_TMP_BASE="unicorn".freeze - DEFAULT_HOST = "0.0.0.0".freeze # default TCP listen host address DEFAULT_PORT = "8080".freeze # default TCP listen port DEFAULT_LISTEN = "#{DEFAULT_HOST}:#{DEFAULT_PORT}".freeze diff --git a/lib/unicorn/http_request.rb b/lib/unicorn/http_request.rb index 0de496f..24da085 100644 --- a/lib/unicorn/http_request.rb +++ b/lib/unicorn/http_request.rb @@ -96,7 +96,7 @@ module Unicorn remain = content_length - http_body.length # must read more data to complete body - @body = remain < Const::MAX_BODY ? StringIO.new : Tempfile.new('') + @body = remain < Const::MAX_BODY ? StringIO.new : Tempfile.new('unicorn') @body.binmode @body.sync = true @body.syswrite(http_body) -- cgit v1.2.3-24-ge0c7