Skip to content

Commit

Permalink
MON-16170 all event string is sent to log if we can't parse output
Browse files Browse the repository at this point in the history
  • Loading branch information
jean-christophe81 committed Dec 14, 2022
1 parent 87b8328 commit 988dee2
Showing 1 changed file with 5 additions and 5 deletions.
10 changes: 5 additions & 5 deletions broker/neb/src/callbacks.cc
Original file line number Diff line number Diff line change
Expand Up @@ -2209,11 +2209,11 @@ int neb::callback_pb_log(int callback_type [[maybe_unused]], void* data) {
log_data = static_cast<nebstruct_log_data*>(data);
le_obj.set_ctime(log_data->entry_time);
le_obj.set_instance_name(config::applier::state::instance().poller_name());
if (log_data->data)
if (!set_pb_log_data(*le,
misc::string::check_string_utf8(log_data->data)))
return 0;

if (log_data->data) {
std::string output = misc::string::check_string_utf8(log_data->data);
le_obj.set_output(output);
set_pb_log_data(*le, output);
}
// Send event.
gl_publisher.write(le);
}
Expand Down

0 comments on commit 988dee2

Please sign in to comment.