Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
win,process: avoid kernel bug with starting Windows Store apps
Make sure this handle is functional. The Windows kernel seems to have a bug that if the first use of AssignProcessToJobObject is for a Windows Store program, subsequent attempts to use the handle with fail with INVALID_PARAMETER (87). This is possilby because all uses of the handle must be for the same Terminal Services session. We can ensure it is tied to our current session now by adding ourself to it. We could remove ourself afterwards, but there doesn't seem to be a reason to. Secondly, we start the process suspended so that we can make sure we added it to the job control object before it does anything itself (such as launch more jobs or exit). Fixes: JuliaLang/julia#51461
- Loading branch information