JetBrains / rd

Reactive Distributed communication framework for .NET, Kotlin, C++. Inspired by Rider IDE.
Apache License 2.0
386 stars 54 forks source link

ProcessWatchdog: no longer fail on exit code 259 on Windows #450

Closed ForNeVeR closed 11 months ago

ForNeVeR commented 11 months ago

Our previous implementation of ProcessWatchdog was susceptible to a well-known issue of GetProcessExitCode: if the process' real exit code is STILL_ALIVE, then there's no way to determine that it has exited, because this number is equal to a special value that function returns for a living process.

This new implementation fixes that, and also introduces a new, better API to pass more arguments (mostly for the purpose of testing).