Google Groups no longer supports new Usenet posts or subscriptions. Historical content remains viewable.
Dismiss

CreateProcess and CloseHandle

111 views
Skip to first unread message

Paul J. Lucas

unread,
Jan 2, 2009, 1:00:59 PM1/2/09
to
If I want to create a new process for a GUI application using CreateProcess()
and not wait for it and have no need of the process handle, can I simple call
CloseHandle() immediately afterwards?

The MSDN example calls CreateProcess(), WaitForSingleObject(), and
CloseHandle(). I have no reason to wait nor any use for the handle.

- Paul

Norman Bullen

unread,
Jan 2, 2009, 7:01:34 PM1/2/09
to
Paul J. Lucas wrote:

If you don't care what happens to the created application, nor what
happens to it, you can close both the process handle and the thread
handle immediately after calling CreateProcess().

--
Norm

To reply, change domain to an adult feline.

0 new messages