forked from SteamWar/SteamWar
Fix stop not working for DevServer starter
This commit is contained in:
@@ -109,11 +109,11 @@ class DevServer extends DefaultTask {
|
||||
Finalizer() {
|
||||
super()
|
||||
doLast {
|
||||
running = false
|
||||
if (processInput != null) {
|
||||
processInput.write(template.endsWith("Velocity") ? "end\n" : "stop\n")
|
||||
processInput.flush()
|
||||
}
|
||||
running = false
|
||||
}
|
||||
}
|
||||
}
|
||||
@@ -245,10 +245,12 @@ class DevServer extends DefaultTask {
|
||||
processInput.newLine()
|
||||
processInput.flush()
|
||||
}
|
||||
processInput.close()
|
||||
}).start()
|
||||
|
||||
process.waitFor()
|
||||
if (processInput != null) {
|
||||
processInput.close()
|
||||
}
|
||||
processInput = null
|
||||
running = false
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user