FIX: Invalid event handle error in Windows Embedded Compact 2013


This article describes an issue that generates an invalid event handle error in Windows Embedded Compact 2013. An update is available to resolve this issue. Before you install this update, all previously issued updates for this product must be installed.


Consider the following scenario:
  • You open a socket from a kernel driver and use an asynchronous IO on the socket in Windows Embedded Compact 2013.
  • You run the WSAEventSelect function together with the FD_CLOSE flag, and then you use the CloseSocket function to close the socket.
  • You call the WaitForSingleObject function that uses the same event handles that are used for the WSAEventSelect function.

In this scenario, the WaitForSingleObject function returns a WAIT_FAILED response. After the call to the CloseSocket function, the WSAEnumNetworkEvents and WSAWaitForMultipleEvents functions fail with a WSA_INVALID_HANDLE error.

Note The nonblocking CloseSocket function starts a graceful socket closure. This process may involve some data exchange. The calling driver must be able to use the WSAWaitForMultipleEvents and WSAEnumNetworkEvents functions in order to wait for a graceful socket closure.

Software update information

Download information

Windows Embedded Compact 2013 Monthly Update (April 2015) is now available from Microsoft. To download this Windows Embedded Compact 2013 monthly update, go to Microsoft OEM Online or MyOEM.


This update is supported only if all previously issued updates for this product have also been installed.

Restart requirement

After you apply this update, you must perform a clean build of the whole platform. To do this, use one of the following methods:
  • On the Build menu, click Clean Solution, and then click Build Solution.
  • On the Build menu, click Rebuild Solution.
You do not have to restart the computer after you apply this software update.

Update replacement information

This update does not replace any other updates.

File information


Microsoft has confirmed that this is a problem in the Microsoft products that are listed in the "Applies to" section.


Learn about the terminology that Microsoft uses to describe software updates.

आलेख ID: 3062879 - पिछली समीक्षा: 21/05/2015 - संशोधन: 1