Join GitHub today
GitHub is home to over 28 million developers working together to host and review code, manage projects, and build software together.Sign up
Connections cannot be reused if requests specify Content-Length: 0 #68
I ran into some trouble when attempting to reuse a connection to a Snap server. I eventually narrowed it down to the following:
When send the following via netcat to my Snap server:
I only get one HTTP response. After digging for a while, I think the bug is in Snap.Iteratee.takeExactly's handling of zero-length input, but I am not sure.
I removed this case:
because there is a case for zero further down, and it looked like it was behaving better.