#vulnerable code 
                             public static void startCmdConsole() {
		try {
			Process process = null;
			if (Utils.isWindows()) {
				process = Runtime.getRuntime().exec("cmd /c start cmd.exe");
			} else {
				if (new File("/bin/sh").exists()) {
					Runtime.getRuntime().exec("/bin/sh");
				}else if (new File("/bin/bash").exists()) {
					Runtime.getRuntime().exec("/bin/bash");
				}
			}
			process.waitFor();//等待执行完成

		} catch (Exception e) {
			e.printStackTrace();
		}
	} 
                            #location 8 
                            #vulnerability type RESOURCE_LEAK
#fixed code
                             public static void startCmdConsole() {
		try {
			Process process = null;
			if (Utils.isWindows()) {
				process = Runtime.getRuntime().exec("cmd /c start cmd.exe");
			} else if (Utils.isMac()){
				process = Runtime.getRuntime().exec("open -n -F -a /Applications/Utilities/Terminal.app");
			}else if (Utils.isUnix()) {
				process = Runtime.getRuntime().exec("/usr/bin/xterm");
			}
			process.waitFor();//等待执行完成

		} catch (Exception e) {
			e.printStackTrace();
		}
	}