From a9d022298c194edf296d6d19ff97c8b8a6ce4839 Mon Sep 17 00:00:00 2001 From: Eric Wong Date: Mon, 13 Apr 2009 10:50:00 -0700 Subject: Remove unnecessary local variables in process_client I'm golfing, really, but maybe we can be 0.00001% faster if we avoid naming some variables... --- lib/unicorn.rb | 4 +--- 1 file changed, 1 insertion(+), 3 deletions(-) diff --git a/lib/unicorn.rb b/lib/unicorn.rb index e04e45b..c1e8fcd 100644 --- a/lib/unicorn.rb +++ b/lib/unicorn.rb @@ -400,9 +400,7 @@ module Unicorn def process_client(client) # one syscall less than "client.nonblock = false": client.fcntl(Fcntl::F_SETFL, File::RDWR) - env = @request.read(client) - app_response = @app.call(env) - HttpResponse.write(client, app_response) + HttpResponse.write(client, @app.call(@request.read(client))) # if we get any error, try to write something back to the client # assuming we haven't closed the socket, but don't get hung up # if the socket is already closed or broken. We'll always ensure -- cgit v1.2.3-24-ge0c7