diff options
author | Eric Wong <normalperson@yhbt.net> | 2013-11-16 04:00:33 +0000 |
---|---|---|
committer | Eric Wong <e@80x24.org> | 2013-11-16 04:02:13 +0000 |
commit | 9500e08721a7fd697e3449738cc20ffcc15aca8f (patch) | |
tree | d785371e1354efbaac4f8229654eaaa4014d16fd /extras | |
parent | 521a703c390a1decbfd4b7ede049880a9afe146c (diff) | |
download | yahns-9500e08721a7fd697e3449738cc20ffcc15aca8f.tar.gz |
The body may contain extra repeated newlines, of course
Diffstat (limited to 'extras')
-rw-r--r-- | extras/exec_cgi.rb | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/extras/exec_cgi.rb b/extras/exec_cgi.rb index 39042af..6924698 100644 --- a/extras/exec_cgi.rb +++ b/extras/exec_cgi.rb @@ -84,7 +84,7 @@ class ExecCgi tmp = pipe.kgio_read(8192) or break head << tmp end - head, body = head.split(/\r?\n\r?\n/) + head, body = head.split(/\r?\n\r?\n/, 2) pipe.body_tip = body env["HTTP_VERSION"] ||= "HTTP/1.0" # stop Rack::Chunked for HTTP/0.9 |