square/okhttp — pull request #592 by nfuller (2014-03-04 15:41:11+00:00)
Title: Modify HttpURLConnection to provide status line.

java.net.CacheResponse is specified to always return the response
headers with an entry of null -> status line.

For URLConnection / HttpURLConnection:
getHeaderField(int) / getHeaderFieldKey(int): The RI docs specify
that implementations *may* treat the 0th header as the status line
with a null key.
getHeaderField(String) or getHeaderFields(): The RI does not
specify the status line behavior for although both methods
appear to return the null mapping in the implementation I looked
at.

Before this change OkHttp treats getHeaderField(String) as having the
null mapping but other methods do not.

This change makes it consistent so that all HttpURLConnection
getHeader*() methods behave as if this mapping exists.