AcTools.Utils.Helpers.ProcessWrapper.ProcessWaitHandle.ProcessWaitHandle C# (CSharp) Method

ProcessWaitHandle() private method

private ProcessWaitHandle ( IntPtr processHandle ) : System
processHandle System.IntPtr
return System
            internal ProcessWaitHandle(IntPtr processHandle) { 
                SafeWaitHandle waitHandle;
                if (!Kernel32.DuplicateHandle(new HandleRef(this, Kernel32.GetCurrentProcess()), processHandle,
                        new HandleRef(this, Kernel32.GetCurrentProcess()),
                        out waitHandle, 0, false, Kernel32.DUPLICATE_SAME_ACCESS)) {
                    Marshal.ThrowExceptionForHR(Marshal.GetHRForLastWin32Error());
                }

                SafeWaitHandle = waitHandle;
            }
        }
ProcessWrapper.ProcessWaitHandle