Re: GetStream.Read behavior changed in .Net 2.0 with respect to ReceiveTimeout
- From: Peter Duniho <NpOeStPeAdM@xxxxxxxxxxxxxxxx>
- Date: Tue, 31 Jul 2007 14:49:31 -0700
Keith Langer wrote:
Hi,
I've noticed that the behavior of ReceiveTimeout has changed
between .Net 1.1 and .Net 2.0 when it comes to the GetStream.Read
method. In .Net 1.1, if the timeout period elapsed, I would get a
System.IO.IOException, but the connection stayed open. I could then
check the InnerException for Errorcode 10060 to verify that it was a
timeout. In .Net 2.0, I still get an IOException when there's a
timeout, but this time the socket closes. This means I would have to
reestablish the connection when I didn't need to before
Actually, you should have been reestablishing the connection before as well. It's just that .NET didn't force you to, even though doing so was important to maintain data integrity.
See this previous thread, discussing this exact issue:
http://groups.google.com/group/microsoft.public.dotnet.framework/browse_thread/thread/8cb606b8d5e49756/864b862266b59310
Pete
.
- Follow-Ups:
- References:
- GetStream.Read behavior changed in .Net 2.0 with respect to ReceiveTimeout
- From: Keith Langer
- GetStream.Read behavior changed in .Net 2.0 with respect to ReceiveTimeout
- Prev by Date: GetStream.Read behavior changed in .Net 2.0 with respect to ReceiveTimeout
- Next by Date: Getting the fully qualified Active Directory domain name (C# / VB.Net)
- Previous by thread: GetStream.Read behavior changed in .Net 2.0 with respect to ReceiveTimeout
- Next by thread: Re: GetStream.Read behavior changed in .Net 2.0 with respect to ReceiveTimeout
- Index(es):
Relevant Pages
|
Loading