Author: cgutman
Date: Mon Aug 1 04:06:55 2011
New Revision: 53017
URL:
http://svn.reactos.org/svn/reactos?rev=53017&view=rev
Log:
[TCPIP]
- Cancel the disconnect timer if the disconnect is cancelled
Modified:
trunk/reactos/drivers/network/tcpip/tcpip/dispatch.c
Modified: trunk/reactos/drivers/network/tcpip/tcpip/dispatch.c
URL:
http://svn.reactos.org/svn/reactos/trunk/reactos/drivers/network/tcpip/tcpi…
==============================================================================
--- trunk/reactos/drivers/network/tcpip/tcpip/dispatch.c [iso-8859-1] (original)
+++ trunk/reactos/drivers/network/tcpip/tcpip/dispatch.c [iso-8859-1] Mon Aug 1 04:06:55
2011
@@ -120,6 +120,7 @@
PTRANSPORT_CONTEXT TranContext;
PFILE_OBJECT FileObject;
UCHAR MinorFunction;
+ PCONNECTION_ENDPOINT Connection;
BOOLEAN DequeuedIrp = TRUE;
IoReleaseCancelSpinLock(Irp->CancelIrql);
@@ -171,7 +172,16 @@
break;
case TDI_DISCONNECT:
+ Connection = (PCONNECTION_ENDPOINT)TranContext->Handle.ConnectionContext;
+
DequeuedIrp = TCPRemoveIRP(TranContext->Handle.ConnectionContext, Irp);
+ if (DequeuedIrp)
+ {
+ if (KeCancelTimer(&Connection->DisconnectTimer))
+ {
+ DereferenceObject(Connection);
+ }
+ }
break;
default: