[TCPIP] Save the date when an ADDRESS_FILE is created
[reactos.git] / drivers / network / tcpip / include / titypes.h
index 7bc8ce3..e63fad2 100644 (file)
@@ -13,6 +13,7 @@
  */
 #define ReferenceObject(Object)                            \
 {                                                          \
+    ASSERT((Object)->RefCount);                            \
     InterlockedIncrement(&((Object)->RefCount));           \
 }
 
@@ -22,6 +23,7 @@
  */
 #define DereferenceObject(Object)                           \
 {                                                           \
+    ASSERT((Object)->RefCount);                             \
     if (InterlockedDecrement(&((Object)->RefCount)) == 0)   \
         (((Object)->Free)(Object));                         \
 }
@@ -135,6 +137,7 @@ typedef struct _ADDRESS_FILE {
     USHORT Family;                        /* Address family */
     USHORT Protocol;                      /* Protocol number */
     USHORT Port;                          /* Network port (network byte order) */
+    LONG Sharers;                         /* Number of file objects with this addr file */
     UCHAR TTL;                            /* Time to live stored in packets sent from this address file */
     UINT DF;                              /* Don't fragment */
     UINT BCast;                           /* Receive broadcast packets */
@@ -151,6 +154,8 @@ typedef struct _ADDRESS_FILE {
     /* Associated listener (see transport/tcp/accept.c) */
     IP_ADDRESS AddrCache;                 /* One entry address cache (destination
                                              address of last packet transmitted) */
+    HANDLE ProcessId;                     /* Creator process ID */
+    LARGE_INTEGER CreationTime;           /* Time of creation */
 
     /* The following members are used to control event notification */
 
@@ -262,7 +267,7 @@ typedef struct _CONNECTION_ENDPOINT {
     PADDRESS_FILE AddressFile;  /* Associated address file object (NULL if none) */
 
     /* Requests */
-    LIST_ENTRY ConnectRequest; /* Queued connect rqueusts */
+    LIST_ENTRY ConnectRequest; /* Queued connect requests */
     LIST_ENTRY ListenRequest;  /* Queued listen requests */
     LIST_ENTRY ReceiveRequest; /* Queued receive requests */
     LIST_ENTRY SendRequest;    /* Queued send requests */
@@ -277,6 +282,8 @@ typedef struct _CONNECTION_ENDPOINT {
     /* Socket state */
     BOOLEAN SendShutdown;
     BOOLEAN ReceiveShutdown;
+    NTSTATUS ReceiveShutdownStatus;
+    BOOLEAN Closing;
 
     struct _CONNECTION_ENDPOINT *Next; /* Next connection in address file list */
 } CONNECTION_ENDPOINT, *PCONNECTION_ENDPOINT;