restsharp/RestSharp — pull request #223 by oliverhanappi (2012-02-20 15:07:51+00:00)
Title: Errors in http layer are not propagated correctly if RawBytes of HttpResponse is null

If RawBytes of HttpResponse is null (e.g. when a timeout occurs), the RestClient.ConvertToRestResponse method throws when getting HttpResponse.Content. As a consequence, an ArgumentNullException gets set as ErrorException in the RestResponse, instead of the real exception.

This pull request fixes the misleading ArgumentNullException.