Fix user property encoding

Summary: related to T11798

Reviewers: ivica

Reviewed By: ivica

Subscribers: miljen, iljazovic

Differential Revision: https://repo.mireo.local/D27532
This commit is contained in:
Korina Šimičević
2024-01-24 13:00:44 +01:00
parent 21d90a9fda
commit 61f17f6e0f
3 changed files with 327 additions and 92 deletions

View File

@@ -390,6 +390,10 @@ bool parse_to_prop(
if constexpr (async_mqtt5::is_vector<prop_type>) {
std::string value;
// key
rv = basic::utf8_.parse(iter, last, ctx, rctx, value);
if (rv) prop.push_back(std::move(value));
// value
rv = basic::utf8_.parse(iter, last, ctx, rctx, value);
if (rv) prop.push_back(std::move(value));
}
@@ -439,7 +443,7 @@ public:
// either rv = false or property with prop_id was not found
if (!rv || iter == saved)
break;
return false;
}
first = iter;