#8 wrap Shell in a dedicated Thread
This commit is contained in:
parent
c86aaccfba
commit
95c2d445a7
@ -26,6 +26,7 @@ public class Nameserver implements INameserver {
|
||||
private NameServerRemote nameServerLocal;
|
||||
|
||||
private Shell shell;
|
||||
private Thread shellThread;
|
||||
|
||||
/**
|
||||
* Creates a new server instance.
|
||||
@ -80,11 +81,12 @@ public class Nameserver implements INameserver {
|
||||
this.shutdown();
|
||||
throw new StopShellException();
|
||||
})));
|
||||
shellThread = new Thread(shell);
|
||||
}
|
||||
|
||||
@Override
|
||||
public void run() {
|
||||
shell.run();
|
||||
shellThread.start();
|
||||
}
|
||||
|
||||
@Override
|
||||
|
||||
Loading…
x
Reference in New Issue
Block a user