mirror of
https://github.com/zeek/zeek.git
synced 2025-10-16 13:38:19 +00:00
Another fix for the new Broker-based remote logging.
This commit is contained in:
parent
5cf7803e68
commit
58a2d06c93
5 changed files with 28 additions and 23 deletions
|
@ -1080,16 +1080,19 @@ threading::Value* bro_broker::data_to_threading_val(broker::data d)
|
|||
|
||||
auto type = broker::get<uint64_t>(*r->get(0));
|
||||
auto present = broker::get<bool>(*r->get(1));
|
||||
auto data = *r->get(2);
|
||||
auto data = r->get(2);
|
||||
|
||||
if ( ! (type && present) )
|
||||
return nullptr;
|
||||
|
||||
if ( *present && ! data )
|
||||
return nullptr;
|
||||
|
||||
auto tv = new threading::Value;
|
||||
tv->type = static_cast<TypeTag>(*type);
|
||||
tv->present = *present;
|
||||
|
||||
if ( present && ! broker::visit(threading_val_converter{tv->type, tv->val}, data) )
|
||||
if ( *present && ! broker::visit(threading_val_converter{tv->type, tv->val}, *data) )
|
||||
{
|
||||
delete tv;
|
||||
return nullptr;
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue