Fix service restart

This commit is contained in:
世界
2023-11-03 01:59:15 +08:00
parent 446ffa4a4d
commit fe5c4b5268
2 changed files with 10 additions and 6 deletions

View File

@@ -156,7 +156,7 @@ class BoxService(
}
if (delayStart) {
delay(200L)
delay(1000L)
}
newService.start()
@@ -171,7 +171,7 @@ class BoxService(
override fun serviceReload() {
status.postValue(Status.Starting)
GlobalScope.launch(Dispatchers.IO) {
runBlocking {
val pfd = fileDescriptor
if (pfd != null) {
pfd.close()