mirror of
https://github.com/asdlokj1qpi233/subconverter.git
synced 2026-11-03 02:02:24 +00:00
Bug fixes
Fix a potential random crash on non-Windows platforms. Fix compatibility with some non-standard Shadowsocks and Shadowcsocks Android subscriptions. Optimize codes.
This commit is contained in:
8 files changed
+70
-38
No files matched your search
+3
-4
@@ -141,7 +141,7 @@ int importItems(string_array &target)
|
||||
while(getline(ss, strLine, delimiter))
|
||||
{
|
||||
lineSize = strLine.size();
|
||||
if(strLine[lineSize - 1] == '\r') //remove line break
|
||||
if(lineSize && strLine[lineSize - 1] == '\r') //remove line break
|
||||
{
|
||||
strLine = strLine.substr(0, lineSize - 1);
|
||||
lineSize--;
|
||||
@@ -1003,8 +1003,7 @@ std::string subconverter(RESPONSE_CALLBACK_ARGS)
|
||||
}
|
||||
else
|
||||
{
|
||||
YAML::Node yamlnode;
|
||||
yamlnode = clash_base;
|
||||
YAML::Node yamlnode = safe_get_clash_base();
|
||||
netchToClash(nodes, yamlnode, extra_group, target == "clashr", ext);
|
||||
output_content = YAML::Dump(yamlnode);
|
||||
}
|
||||
@@ -1059,7 +1058,7 @@ std::string subconverter(RESPONSE_CALLBACK_ARGS)
|
||||
else
|
||||
{
|
||||
INIReader ini;
|
||||
ini = mellow_base;
|
||||
ini = safe_get_mellow_base();
|
||||
netchToMellow(nodes, ini, rca, extra_group, ext);
|
||||
output_content = ini.ToString();
|
||||
}
|
||||
|
||||
Reference in new issue
Block a user