mirror of
https://github.com/monero-project/monero.git
synced 2025-08-22 08:09:36 -04:00
Fix copies in ZMQ input/output
This commit is contained in:
parent
f90a267fa3
commit
f8ecd31743
1 changed files with 2 additions and 4 deletions
|
@ -57,9 +57,7 @@
|
|||
|
||||
#define GET_FROM_JSON_OBJECT(source, dst, key) \
|
||||
OBJECT_HAS_MEMBER_OR_THROW(source, #key) \
|
||||
decltype(dst) dstVal##key; \
|
||||
cryptonote::json::fromJsonValue(source[#key], dstVal##key); \
|
||||
dst = dstVal##key;
|
||||
cryptonote::json::fromJsonValue(source[#key], dst)
|
||||
|
||||
namespace cryptonote
|
||||
{
|
||||
|
@ -377,7 +375,7 @@ inline typename std::enable_if<sfinae::is_vector_like<Vec>::value, void>::type t
|
|||
static_assert(!std::is_same<value_type, unsigned char>::value, "encoding an array of unsigned char is faster as hex");
|
||||
|
||||
dest.StartArray();
|
||||
for (auto t : vec)
|
||||
for (const auto& t : vec)
|
||||
toJsonValue(dest, t);
|
||||
dest.EndArray();
|
||||
}
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue