mirror of
https://github.com/v2rayA/v2rayA.git
synced 2026-11-20 23:02:25 +03:00
fix: error should not be ignored when core process is killed
This commit is contained in:
1 parent
921fa29e0b
commit
d231beceb0
1 file changed
+3
-5
@@ -50,7 +50,9 @@ func RestartV2rayService(saveStatus bool) (err error) {
|
||||
return newError("cannot find GFWList files. update GFWList and try again")
|
||||
}
|
||||
//关闭transparentProxy,防止v2ray在启动DOH时需要解析域名
|
||||
_ = killV2ray(saveStatus)
|
||||
if err = killV2ray(saveStatus); err != nil {
|
||||
return
|
||||
}
|
||||
v2rayBinPath, err := where.GetV2rayBinPath()
|
||||
if err != nil {
|
||||
return
|
||||
@@ -271,10 +273,6 @@ func killV2ray(saveStatus bool) (err error) {
|
||||
if err != nil {
|
||||
return
|
||||
}
|
||||
_, err = CoreProcess().Wait()
|
||||
if err != nil {
|
||||
return
|
||||
}
|
||||
if saveStatus {
|
||||
SetCoreProcess(nil)
|
||||
}
|
||||
|
||||
Reference in new issue
Block a user