> I was getting a response from an HTTP Server where the Status was 
> set to 0 (instead of 1xx-5xx).  This was causing an exception in 
> my application.
> 
> Although this is an error on the server side, shouldn't the code 
> be changed from:
>  
> procedure THttpCli.GetHeaderLineNext;
> [...]
>   FStatusCode   := StrToInt(Copy(FLastResponse, tmpInt, 3));
> [...]
> 
> To:
> 
> [...]
>   FStatusCode   := StrToIntDef(Copy(FLastResponse, tmpInt, 3), 
> 0); [...]

ICS generally uses atoi instead of StrToInt which stops processing when
a non-numeric character is found, I'll change it. 

Angus

-- 
To unsubscribe or change your settings for TWSocket mailing list
please goto http://lists.elists.org/cgi-bin/mailman/listinfo/twsocket
Visit our website at http://www.overbyte.be

Reply via email to