提交 1555850d 编写于 作者: R rriggs

8036571: (process) Process process arguments carefully

Reviewed-by: alanb, ahgross, jeff, robm
上级 91e02138
......@@ -1019,6 +1019,12 @@ public final class ProcessBuilder
String dir = directory == null ? null : directory.toString();
for (int i = 1; i < cmdarray.length; i++) {
if (cmdarray[i].indexOf('\u0000') >= 0) {
throw new IOException("invalid null character in command");
}
}
try {
return ProcessImpl.start(cmdarray,
environment,
......
Markdown is supported
0% .
You are about to add 0 people to the discussion. Proceed with caution.
先完成此消息的编辑!
想要评论请 注册