Re: How to Valid Event Handle
From: Kent Lottis [MS] (kentlott_at_online.microsoft.com)
Date: 03/29/04
- Next message: Robert Magyar: "RE: Tools for flash image and customer files onto NandFlash for mass production"
- Previous message: Michael J. Salamone [eMVP]: "Re: How to Valid Event Handle"
- In reply to: John: "How to Valid Event Handle"
- Messages sorted by: [ date ] [ thread ]
Date: Mon, 29 Mar 2004 09:23:27 -0800
There are two things you can do
- check the result of DuplicateHandle before referencing your local copy of
the event handle
- keep track of the event handle in the device context you create and return
in XXX_Open. When you get the corresponding XXX_Close, make sure to release
the duplicate event handle using CloseHandle.
Note that you shouldn't have to check the return code of SetEvent once
you've duplicated the handle: if the client application deletes it's copy of
the event handle, the object sticks around until you release it from your
side.
-- Kent Lottis Dev Lead, Windows CE Multimedia Microsoft Corporation This posting is provided "AS IS" with no warranties, and confers no rights. You assume all risk for your use. © Microsoft Corporation. All rights reserved.
- Next message: Robert Magyar: "RE: Tools for flash image and customer files onto NandFlash for mass production"
- Previous message: Michael J. Salamone [eMVP]: "Re: How to Valid Event Handle"
- In reply to: John: "How to Valid Event Handle"
- Messages sorted by: [ date ] [ thread ]
Relevant Pages
|
|