|
@@ -1654,13 +1654,11 @@ begin
|
|
|
var NulDevice := CreateFile('\\.\NUL', GENERIC_READ,
|
|
|
FILE_SHARE_READ or FILE_SHARE_WRITE, @SecurityAttributes,
|
|
|
OPEN_EXISTING, 0, 0);
|
|
|
- if NulDevice = INVALID_HANDLE_VALUE then
|
|
|
- { In case the NUL device is missing (which it inexplicably seems to
|
|
|
- be for some users, per web search), don't treat it as a fatal
|
|
|
- error. Just leave FStdInNulDevice at 0. It's not ideal, but the
|
|
|
- child process likely won't even attempt to access stdin anyway. }
|
|
|
- LogErrorFmt('Failed to open NUL device (%d). Will pass NULL handle for stdin.', [GetLastError])
|
|
|
- else
|
|
|
+ { In case the NUL device is missing (which it inexplicably seems to
|
|
|
+ be for some users, per web search), don't treat it as a fatal
|
|
|
+ error. Just leave FStdInNulDevice at 0. It's not ideal, but the
|
|
|
+ child process likely won't even attempt to access stdin anyway. }
|
|
|
+ if NulDevice <> INVALID_HANDLE_VALUE then
|
|
|
FStdInNulDevice := NulDevice;
|
|
|
|
|
|
PipeCreate(FStdOutPipeRead, FStdOutPipeWrite, SecurityAttributes);
|