Skip to content

Commit

Permalink
fix(subparser): SIP008 decoder
Browse files Browse the repository at this point in the history
fix tindy2013#366

The SIP008 subscription can not be converted correctly when the member "remarks" does not exist.
  • Loading branch information
cubercsl committed Aug 23, 2021
1 parent 85ae329 commit d47b7a6
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion src/parser/subparser.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -495,7 +495,7 @@ void explodeSSConf(std::string content, std::vector<Proxy> &nodes)
json.Parse(content.data());
if(json.HasParseError())
return;
const char *section = json.HasMember("version") && json.HasMember("remarks") && json.HasMember("servers") ? "servers" : "configs";
const char *section = json.HasMember("version") && json.HasMember("servers") ? "servers" : "configs";
if(!json.HasMember(section))
return;
GetMember(json, "remarks", group);
Expand Down

0 comments on commit d47b7a6

Please sign in to comment.