mirror of
https://code.briarproject.org/briar/briar.git
synced 2026-02-18 05:39:53 +01:00
@@ -193,8 +193,17 @@ class TorPlugin implements DuplexPlugin, EventHandler, EventListener {
|
|||||||
// Log the process's standard output until it detaches
|
// Log the process's standard output until it detaches
|
||||||
if (LOG.isLoggable(INFO)) {
|
if (LOG.isLoggable(INFO)) {
|
||||||
Scanner stdout = new Scanner(torProcess.getInputStream());
|
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();
|
stdout.close();
|
||||||
|
stderr.close();
|
||||||
}
|
}
|
||||||
try {
|
try {
|
||||||
// Wait for the process to detach or exit
|
// Wait for the process to detach or exit
|
||||||
|
|||||||
Reference in New Issue
Block a user