commons-user mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Bryce Fischer <br...@berzerker-soft.com>
Subject Re: [HTTPClient] Getting Protocol Exception
Date Fri, 09 Dec 2005 18:51:52 GMT
On 12/9/05, Bryce Fischer <bryce@berzerker-soft.com> wrote:
> [...]
> DEBUG [httpclient.wire.header] << "<data removed>[\r][\n]"
> DEBUG [httpclient.wire.header] << "null[\r][\n]"

Well, stepping through the source code, I noticed this:

File: org.apache.commons.httpclient.HttpMethodBase
Line: 1846
Method: protected void readStatusLine(HttpState state, HttpConnection conn)

            } else if (s == null || count >= maxGarbageLines) {
                // Giving up
                throw new ProtocolException("The server " + conn.getHost() +
                        " failed to respond with a valid HTTP response");
            }

I also noticed that the last line the server sends is a null... So I
guess I have my answer. Doesn't look like much I can do.
> First thing I noticed was that the data was being returned with the
> header. That is why I was trying to set the parameters in the code
> above (it didn't work without the parameters either).

---------------------------------------------------------------------
To unsubscribe, e-mail: commons-user-unsubscribe@jakarta.apache.org
For additional commands, e-mail: commons-user-help@jakarta.apache.org


Mime
View raw message