Hi, I´m developing a netsh thread that keeps netsh open so I just have to call it once.
Everything worked fine until I tried my app in a Spanish-Windows enviroment...
netsh tells me that it can´t find the interfaces I´m specifying on the commands and I´m pretty sure that the cause of this is because some of these interfaces names have accents...
So, I´m guessing this is a encoding problem...
my code looks like this:
private netshOutStream = new BufferedOutputStream(netshProcess.getOutputStream());
private PrintWriter netshWriter = new PrintWriter(netshOutStream, true);
Scanner fi = new Scanner(netshProcess.getInputStream());
public void executeCommand(String command) {
System.out.println("Executing: " + command);
String str = "";
netshWriter.println(command);
fi.skip("\\s*");
str = fi.nextLine();
System.out.println(str);
}
Can anyone help me?
Thank you!!!