Discussion:
winhttp reports no error, but windows reset connection
(too old to reply)
mmurgan
2008-11-13 19:58:02 UTC
Permalink
Hello,

I have a problem with winhttp. So, I use winhttp to download some files, and
if the server is too loaded, I receive an ERROR_WINHTTP_TIMEOUT, which is
fine. I close the request and the connection, and I retry opening the
connection and sending the request. After a few retryings on this manner, not
necessary on the same file, I see with wireshark that in the middle of
downloading of one file, I send to server a reset packet (this is happening
after the timeout period expires) but in the code I receive no error or
timeout error. I do not close any connection in this case, and also the file
is not completely downloaded and I do not receive any errors. If you have any
idea how to solve this I'll be very gratefull - I mean how can I know that
windows cut my connection, or that another timeout has occured.

Thanks in advance,
Mihai Murgan
Ari Pernick [MSFT]
2008-11-25 15:43:01 UTC
Permalink
How do you currently determine you are done with the response entitiy body?
Post by mmurgan
Hello,
I have a problem with winhttp. So, I use winhttp to download some files, and
if the server is too loaded, I receive an ERROR_WINHTTP_TIMEOUT, which is
fine. I close the request and the connection, and I retry opening the
connection and sending the request. After a few retryings on this manner, not
necessary on the same file, I see with wireshark that in the middle of
downloading of one file, I send to server a reset packet (this is happening
after the timeout period expires) but in the code I receive no error or
timeout error. I do not close any connection in this case, and also the file
is not completely downloaded and I do not receive any errors. If you have any
idea how to solve this I'll be very gratefull - I mean how can I know that
windows cut my connection, or that another timeout has occured.
Thanks in advance,
Mihai Murgan
Loading...