Permalink
Browse files

also split chunk header on semicolon

just in case a client is using chunk extensions
  • Loading branch information...
1 parent 82508b7 commit 4b7c6c1d472af763427620af27dc933459774a6e Bryan Fink committed Nov 18, 2010
Showing with 1 addition and 0 deletions.
  1. +1 −0 src/webmachine_request.erl
View
1 src/webmachine_request.erl
@@ -445,6 +445,7 @@ read_chunk_length(Socket, MaybeLastChunk) ->
mochiweb_socket:setopts(Socket, [{packet, raw}]),
Splitter = fun (C) ->
C =/= $\r andalso C =/= $\n andalso C =/= $
+ andalso C =/= 59 % semicolon
end,
{Hex, _Rest} = lists:splitwith(Splitter, binary_to_list(Header)),
case Hex of

0 comments on commit 4b7c6c1

Please sign in to comment.