Merge pull request #5939 from eatkins/running-init

Initialize value before starting thread
This commit is contained in:
eugene yokota 2020-10-11 15:39:54 -04:00 committed by GitHub
commit ca8c1e704d
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
1 changed files with 1 additions and 1 deletions

View File

@ -608,9 +608,9 @@ object Terminal {
*/
private class ReadThread extends Thread with AutoCloseable {
val result = new LinkedBlockingQueue[Integer]
val running = new AtomicBoolean(true)
setDaemon(true)
start()
val running = new AtomicBoolean(true)
override def run(): Unit = while (running.get) {
bootInputStreamHolder.get match {
case null =>