mirror of
https://github.com/zeromq/libzmq.git
synced 2024-12-31 01:43:02 +08:00
Don't add empty metadata to received messages
This commit is contained in:
parent
f721a7ad07
commit
e95b477a87
@ -142,7 +142,8 @@ int zmq::mechanism_t::parse_metadata (const unsigned char *ptr_,
|
|||||||
}
|
}
|
||||||
if (zap_flag) {
|
if (zap_flag) {
|
||||||
assert (metadata == NULL);
|
assert (metadata == NULL);
|
||||||
metadata = new (std::nothrow) metadata_t (dict);
|
if (!dict.empty ())
|
||||||
|
metadata = new (std::nothrow) metadata_t (dict);
|
||||||
}
|
}
|
||||||
return 0;
|
return 0;
|
||||||
}
|
}
|
||||||
|
Loading…
x
Reference in New Issue
Block a user