delete cache ss/r config file when process exit

This commit is contained in:
世界 2020-04-04 15:22:36 +08:00
parent a49cfa03c4
commit 0576309ff1
No known key found for this signature in database
GPG Key ID: CD109927C34A63C4
2 changed files with 14 additions and 2 deletions

View File

@ -46,10 +46,16 @@ class ShadowsocksLoader {
"-b", "127.0.0.1",
"-t", "600",
"-c", cacheCfg.path,
"-l", port.toString()))
"-l", port.toString())) {
cacheCfg.delete()
}
}.onFailure {
cacheCfg.delete()
FileLog.e(it)
}

View File

@ -48,10 +48,16 @@ class ShadowsocksRLoader {
"--host", bean.host,
"-t", "600",
"-c", cacheCfg.path,
"-l", port.toString()))
"-l", port.toString())) {
cacheCfg.delete()
}
}.onFailure {
cacheCfg.delete()
FileLog.e(it)
}