mirror of
https://github.com/clash-verge-rev/clash-verge-rev.git
synced 2026-04-18 16:30:32 +08:00
fix(config): restrict restart_core_needed mutability to non-Windows to avoid unused-mut
This commit is contained in:
parent
c41db51f81
commit
895e54f7ec
@ -112,6 +112,14 @@ fn determine_update_flags(patch: &IVerge) -> UpdateFlags {
|
|||||||
let enable_proxy_guard = patch.enable_proxy_guard;
|
let enable_proxy_guard = patch.enable_proxy_guard;
|
||||||
let proxy_guard_duration = patch.proxy_guard_duration;
|
let proxy_guard_duration = patch.proxy_guard_duration;
|
||||||
|
|
||||||
|
#[cfg(target_os = "windows")]
|
||||||
|
let restart_core_needed = socks_enabled.is_some()
|
||||||
|
|| http_enabled.is_some()
|
||||||
|
|| socks_port.is_some()
|
||||||
|
|| http_port.is_some()
|
||||||
|
|| mixed_port.is_some()
|
||||||
|
|| enable_external_controller.is_some();
|
||||||
|
#[cfg(not(target_os = "windows"))]
|
||||||
let mut restart_core_needed = socks_enabled.is_some()
|
let mut restart_core_needed = socks_enabled.is_some()
|
||||||
|| http_enabled.is_some()
|
|| http_enabled.is_some()
|
||||||
|| socks_port.is_some()
|
|| socks_port.is_some()
|
||||||
|
|||||||
Loading…
x
Reference in New Issue
Block a user