44 references to ProcessUtils
System.Diagnostics.Process (44)
Microsoft\Win32\SafeHandles\SafeProcessHandle.cs (10)
135if (!ProcessUtils.PlatformSupportsProcessStartAndKill) 180if (!ProcessUtils.PlatformSupportsProcessStartAndKill) 185SerializationGuard.ThrowIfDeserializationInProgress("AllowProcessCreation", ref ProcessUtils.s_cachedSerializationSwitch); 198childInputHandle ??= nullDeviceHandle ?? (ProcessUtils.PlatformSupportsConsole ? Console.OpenStandardInputHandle() : null); 199childOutputHandle ??= nullDeviceHandle ?? (ProcessUtils.PlatformSupportsConsole ? Console.OpenStandardOutputHandle() : null); 200childErrorHandle ??= nullDeviceHandle ?? (ProcessUtils.PlatformSupportsConsole ? Console.OpenStandardErrorHandle() : null); 296return TryWaitForExitCore(ProcessUtils.ToTimeoutMilliseconds(timeout), out exitStatus); 320if (!ProcessUtils.PlatformSupportsProcessStartAndKill) 325return WaitForExitOrKillOnTimeoutCore(ProcessUtils.ToTimeoutMilliseconds(timeout)); 416if (!ProcessUtils.PlatformSupportsProcessStartAndKill)
Microsoft\Win32\SafeHandles\SafeProcessHandle.Unix.cs (20)
111if (!ProcessUtils.PlatformSupportsProcessStartAndKill) 218ProcessUtils.EnsureInitialized(); 237(userId, groupId, groups) = ProcessUtils.GetUserAndGroupIds(startInfo); 242filename = ProcessUtils.ResolvePath(startInfo.FileName); 243argv = ProcessUtils.ParseArgv(startInfo); 269(userId, groupId, groups) = ProcessUtils.GetUserAndGroupIds(startInfo); 286string? filename = ProcessUtils.ResolveExecutableForShellExecute(startInfo.FileName, cwd); 289string[] argv = ProcessUtils.ParseArgv(startInfo); 310string[] openFileArgv = ProcessUtils.ParseArgv(startInfo, filename, ignoreArguments: true); 327=> ProcessUtils.IsTerminal(stdinHandle) || ProcessUtils.IsTerminal(stdoutHandle) || ProcessUtils.IsTerminal(stderrHandle); 341throw ProcessUtils.CreateExceptionForErrorStartingProcess(error.GetErrorMessage(), error.RawErrno, startInfo.FileName, cwd); 348ProcessUtils.s_processStartLock.EnterReadLock(); 353ProcessUtils.ConfigureTerminalForChildProcesses(1); 382ProcessUtils.s_processStartLock.ExitReadLock(); 390ProcessUtils.s_processStartLock.EnterWriteLock(); 391ProcessUtils.ConfigureTerminalForChildProcesses(-1); 392ProcessUtils.s_processStartLock.ExitWriteLock(); 401throw ProcessUtils.CreateExceptionForErrorStartingProcess(new Interop.ErrorInfo(errno).GetErrorMessage(), errno, resolvedFilename, cwd);
System\Diagnostics\Process.cs (8)
752public bool WaitForInputIdle(TimeSpan timeout) => WaitForInputIdle(ProcessUtils.ToTimeoutMilliseconds(timeout)); 1192if (!ProcessUtils.PlatformSupportsProcessStartAndKill) 1200SerializationGuard.ThrowIfDeserializationInProgress("AllowProcessCreation", ref ProcessUtils.s_cachedSerializationSwitch); 1220bool requiresLock = anyRedirection && !ProcessUtils.SupportsAtomicNonInheritablePipeCreation; 1224ProcessUtils.s_processStartLock.EnterWriteLock(); 1260ProcessUtils.s_processStartLock.ExitWriteLock(); 1276else if (ProcessUtils.PlatformSupportsConsole) 1499public bool WaitForExit(TimeSpan timeout) => WaitForExit(ProcessUtils.ToTimeoutMilliseconds(timeout));
System\Diagnostics\Process.Linux.cs (1)
77string? pathToProgram = ProcessUtils.FindProgramInPath(program);
System\Diagnostics\Process.Multiplexing.cs (2)
151? ProcessUtils.ToTimeoutMilliseconds(timeout.Value) 635? ProcessUtils.ToTimeoutMilliseconds(timeout.Value)
System\Diagnostics\Process.Unix.cs (1)
57if (!ProcessUtils.PlatformSupportsProcessStartAndKill)
System\Diagnostics\ProcessStartInfo.cs (1)
575if (inheritedHandles is null || inheritedHandles.Length == 0 || !ProcessUtils.PlatformSupportsConsole)
System\Diagnostics\ProcessWaitState.Unix.cs (1)
569ProcessUtils.ConfigureTerminalForChildProcesses(-1, configureConsole);