mirror of
https://github.com/Telecominfraproject/wlan-cloud-lib-cppkafka.git
synced 2025-11-01 11:07:56 +00:00
* Added asserts when building a HeaderList and removed checks for handle
validity. * Removed explicit move semantic when cloning a MessageBuilder. * Renamed clone() to try_clone() in ClonablePtr class.
This commit is contained in:
@@ -133,6 +133,9 @@ public:
|
||||
*/
|
||||
void set_header_list(const HeaderListType& headers) {
|
||||
assert(handle_);
|
||||
if (!headers) {
|
||||
return; //nothing to set
|
||||
}
|
||||
rd_kafka_headers_t* handle_copy = rd_kafka_headers_copy(headers.get_handle());
|
||||
rd_kafka_message_set_headers(handle_.get(), handle_copy);
|
||||
header_list_ = HeaderListType::make_non_owning(handle_copy);
|
||||
|
||||
Reference in New Issue
Block a user