utils: make unpackMsg take const Blob& and inline

Change the template unpackMsg to accept a const Blob& to avoid an
unnecessary copy of the Blob argument. Move the non-template unpackMsg
(returning msgpack::unpacked) into the header as an inline function and
remove its out-of-line definition from src/utils.cpp. Update
declarations accordingly.
This commit is contained in:
Adrien Béraud committed 2026-02-05 21:31:42 -05:00
1 parent aa000ee586
commit 73dc55155e
2 files changed
+6 -8

No files matched your search

-6
View File
@@ -282,12 +282,6 @@ unpackBlob(const msgpack::object& o)
}
}
msgpack::unpacked
unpackMsg(Blob b)
{
return msgpack::unpack((const char*) b.data(), b.size());
}
msgpack::object*
findMapValue(const msgpack::object& map, const char* key, size_t key_length)
{