Can't execute javac or other command line applications in Java using ProcessBuilder under Windows 7

前端 未结 3 1147
梦毁少年i
梦毁少年i 2021-01-29 02:33

I\'m trying to execute javac from Java using ProcessBuilder but i get no output and nothing happens. I tried reading the input stream (as there is a bug where the process hangs

3条回答
  •  傲寒
    傲寒 (楼主)
    2021-01-29 02:52

    You have to read from process.getInputStream() yourself. As far as I know, processes' output doesn't automatically show on stdout.

提交回复
热议问题