From df909bdb60ceb277ec495382e6b4b7e722810a19 Mon Sep 17 00:00:00 2001 From: Tindy X <49061470+tindy2013@users.noreply.github.com> Date: Fri, 6 Dec 2019 10:11:27 +0800 Subject: [PATCH] Fix Shadowsocks Plugin missing when parsing Clash configuration --- speedtestutil.cpp | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/speedtestutil.cpp b/speedtestutil.cpp index 7bbfb24..3ce6201 100644 --- a/speedtestutil.cpp +++ b/speedtestutil.cpp @@ -854,9 +854,9 @@ void explodeClash(Node yamlnode, std::string custom_port, int local_port, std::v yamlnode["Proxy"][i]["cipher"] >> cipher; yamlnode["Proxy"][i]["password"] >> password; - if(yamlnode["Proxy"][i]["plugin"].IsDefined()) + if(yamlnode["Proxy"][i]["plugin"].IsDefined() && yamlnode["Proxy"][i]["plugin"].as() == "obfs") { - yamlnode["Proxy"][i]["plugin"] >> plugin; + plugin = "simple-obfs"; if(yamlnode["Proxy"][i]["plugin-opts"].IsDefined()) { yamlnode["Proxy"][i]["plugin-opts"]["mode"] >> pluginopts_mode;