changeset 74786:4f26e07fd85d

(_sys_wait_accept): Fix handle leak.
author Kim F. Storm <storm@cua.dk>
date Thu, 21 Dec 2006 12:47:06 +0000
parents 98b7d08f05e3
children 6894f7009c05
files src/w32.c
diffstat 1 files changed, 2 insertions(+), 2 deletions(-) [+]
line wrap: on
line diff
--- a/src/w32.c	Thu Dec 21 12:46:56 2006 +0000
+++ b/src/w32.c	Thu Dec 21 12:47:06 2006 +0000
@@ -3698,10 +3698,10 @@
     {
       rc = WaitForSingleObject (hEv, INFINITE);
       pfn_WSAEventSelect (SOCK_HANDLE (fd), NULL, 0);
-      pfn_WSACloseEvent (hEv);
       if (rc == WAIT_OBJECT_0)
 	cp->status = STATUS_READ_SUCCEEDED;
     }
+  pfn_WSACloseEvent (hEv);
 
   return cp->status;
 }
@@ -4127,7 +4127,7 @@
       shut_down_emacs (0, 0, Qnil);
     }
 
-  /* Allow other handlers to handle this signal.  */  
+  /* Allow other handlers to handle this signal.  */
   return FALSE;
 }