Fix subscription info not being passed to the response.
Use stable sort for sorting nodes.
This commit is contained in:
Tindy X 2021-06-11 21:38:15 +08:00
parent e140c24f3d
commit e21f511ddb
No known key found for this signature in database
GPG Key ID: C6AD413169968D58
2 changed files with 2 additions and 2 deletions

View File

@ -34,7 +34,7 @@ void copyNodes(std::vector<Proxy> &source, std::vector<Proxy> &dest)
int addNodes(std::string link, std::vector<Proxy> &allNodes, int groupID, parse_settings &parse_set)
{
std::string &proxy = *parse_set.proxy, subInfo = *parse_set.sub_info;
std::string &proxy = *parse_set.proxy, &subInfo = *parse_set.sub_info;
string_array &exclude_remarks = *parse_set.exclude_remarks;
string_array &include_remarks = *parse_set.include_remarks;
string_array &stream_rules = *parse_set.stream_rules;

View File

@ -273,7 +273,7 @@ void preprocessNodes(std::vector<Proxy> &nodes, extra_settings &ext)
return 0;
return compare(a, b);
};
std::sort(nodes.begin(), nodes.end(), comparer);
std::stable_sort(nodes.begin(), nodes.end(), comparer);
failed = false;
}, gScriptCleanContext);
}