mirror of
https://github.com/ZLMediaKit/ZLMediaKit.git
synced 2024-11-25 20:27:34 +08:00
完善key-value解析代码
This commit is contained in:
parent
246f446142
commit
c2bf2928d0
@ -148,7 +148,10 @@ StrCaseMap Parser::parseArgs(const string &str, const char *pair_delim, const ch
|
||||
auto val = trim(FindField(key_val.data(), key_delim, NULL));
|
||||
ret.emplace_force(key, val);
|
||||
} else {
|
||||
ret.emplace_force(key_val, "");
|
||||
trim(key_val);
|
||||
if (!key_val.empty()) {
|
||||
ret.emplace_force(key_val, "");
|
||||
}
|
||||
}
|
||||
}
|
||||
return ret;
|
||||
|
Loading…
Reference in New Issue
Block a user