Bug 46133

Summary: ProcessLauncherWin.cpp leaks the child process handle
Product: WebKit Reporter: Anders Carlsson <andersca>
Component: WebKit2Assignee: Adam Roben (:aroben) <aroben>
Status: RESOLVED FIXED    
Severity: Normal CC: andersca
Priority: P2 Keywords: InRadar, PlatformOnly
Version: 528+ (Nightly build)   
Hardware: PC   
OS: Windows XP   
Attachments:
Description Flags
Stop leaking the web process's process handle on Windows andersca: review+

Description Anders Carlsson 2010-09-20 16:30:00 PDT
We should ::CloseHandle the handle.
Comment 1 Adam Roben (:aroben) 2010-09-20 16:31:31 PDT
According to MSDN:

If the function succeeds, be sure to call the CloseHandle function to close the hProcess and hThread handles when you are finished with them. Otherwise, when the child process exits, the system cannot clean up the process structures for the child process because the parent process still has open handles to the child process. However, the system will close these handles when the parent process terminates, so the structures related to the child process object would be cleaned up at this point.

http://msdn.microsoft.com/en-us/library/ms684873(v=VS.85).aspx
Comment 2 Adam Roben (:aroben) 2010-09-20 16:32:05 PDT
<rdar://problem/8455343>
Comment 3 Adam Roben (:aroben) 2010-09-27 07:01:14 PDT
Created attachment 68905 [details]
Stop leaking the web process's process handle on Windows
Comment 4 Adam Roben (:aroben) 2010-09-27 08:23:45 PDT
Committed r68391: <http://trac.webkit.org/changeset/68391>