http-kit/http-kit — pull request #131 by pyrtsa (2014-03-10 12:32:52+00:00)
Title: Bugfix: Allow empty Reason-Phrase

With the current code in master, the condition in https://github.com/http-kit/http-kit/blob/master/src/java/org/httpkit/client/Decoder.java#L55-L58 still fails to work for a correctly behaving HTTP server that just happens to omit the `Reason-Phrase` returning a `Status-Line` with a space following the `Status-Code`, e.g. `"HTTP/1.1 200 "`.

This pull request fixes HttpUtils/findEndOfString to handle this case correctly, and adds a set of unit tests that check the behavior of `org.httpkit.client.Decoder`.