def waitAndCloseHandle(processHandle):
 WaitForSingleObject(processHandle, INFINITE)
 CloseHandle(processHandle)

def waitAndCloseHandle ( processHandle ) : WaitForSingleObject ( processHandle , INFINITE ) CloseHandle ( processHandle )
waits till spawned process finishes and closes the handle for it .