Skip to content
Snippets Groups Projects
Commit d9a62a04 authored by akwizgran's avatar akwizgran
Browse files

Merge branch 'print_tor_errors' into 'master'

Make Tor boot more verbose

See merge request !486
parents 15ba7327 ef74db65
No related branches found
No related tags found
No related merge requests found
......@@ -197,8 +197,17 @@ class TorPlugin implements DuplexPlugin, EventHandler, EventListener {
// Log the process's standard output until it detaches
if (LOG.isLoggable(INFO)) {
Scanner stdout = new Scanner(torProcess.getInputStream());
while (stdout.hasNextLine()) LOG.info(stdout.nextLine());
Scanner stderr = new Scanner(torProcess.getErrorStream());
while (stdout.hasNextLine() || stderr.hasNextLine()){
if(stdout.hasNextLine()) {
LOG.info(stdout.nextLine());
}
if(stderr.hasNextLine()){
LOG.info(stderr.nextLine());
}
}
stdout.close();
stderr.close();
}
try {
// Wait for the process to detach or exit
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment