问题遇到的现象和发生背景
######IDEA 项目测试环境
@Test
public void test222() {
BufferedReader br = null;
try {
Process p = Runtime.getRuntime().exec("net user");
br = new BufferedReader(new InputStreamReader(p.getInputStream(), Charset.forName("GBK")));
String line = null;
while ((line = br.readLine()) != null) {
System.out.println(line);
}
} catch (IOException e) {
e.printStackTrace();
} finally {
if (br != null) {
try {
br.close();
} catch (Exception e) {
e.printStackTrace();
}
}
}