RFR [8023130] (process) ProcessBuilder#inheritIO does not work on Windows
Ivan Gerasimov
ivan.gerasimov at oracle.com
Fri Aug 23 03:07:18 UTC 2013
Hello everybody!
The method ProcessBuilder#inheritIO() is reported to not have any effect
on Windows platform.
The same story is with redirectOutput/Input/Error(Redirect.INHERIT) methods.
As the result, standard in/out/err aren't inherited.
It turn out that the culprit is the CREATE_NO_WINDOW flag passed to
CreateProcessW().
MS doc says about this flag: "The process is a console application that
is being run without a console window."
CREATE_NO_WINDOW flag was added with the fix for
http://bugs.sun.com/view_bug.do?bug_id=4244515 to suppress a console
window on a newly created process, when it is created from a program
launched with javaw.exe.
Thus, I left this flag only for cases when the program doesn't have a
console associated with it.
Would you please help review a fix for this problem?
BUGURL: http://bugs.sun.com/view_bug.do?bug_id=8023130
WEBREV: http://cr.openjdk.java.net/~igerasim/8023130/0/webrev/
Sincerely yours,
Ivan Gerasimov
More information about the core-libs-dev
mailing list