From a7e9a5fa2566c8e073800548c10c9b753c924921 Mon Sep 17 00:00:00 2001 From: Jesse Ditson Date: Sat, 2 Mar 2013 18:09:56 -0800 Subject: [PATCH] fix #27 - make sure content-length is an int before trying to add the length of the insert. --- lib/proxy.js | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/lib/proxy.js b/lib/proxy.js index b0dcddd..9e1c7c4 100644 --- a/lib/proxy.js +++ b/lib/proxy.js @@ -79,7 +79,7 @@ function createServer (insert, skip, req, bounce) { }, {}) ; if (headers['content-length']) { - headers['content-length'] += insert.length; + headers['content-length'] = parseInt(headers['content-length'],10) + insert.length; } delete headers.etag; delete headers['last-modified'];