Skip to content

Commit

Permalink
cfg-tree: add trace log entry about pipe creation with persist-name
Browse files Browse the repository at this point in the history
Signed-off-by: Hofi <hofione@gmail.com>
  • Loading branch information
HofiOne committed Oct 21, 2024
1 parent abbee2c commit 73b4434
Showing 1 changed file with 8 additions and 3 deletions.
11 changes: 8 additions & 3 deletions lib/cfg-tree.c
Original file line number Diff line number Diff line change
Expand Up @@ -679,10 +679,15 @@ cfg_tree_register_initialized_pipe(CfgTree *self, LogPipe *s)
{
main_loop_assert_main_thread();

if (FALSE == g_hash_table_contains(self->pipes_with_persis_name, s) && log_pipe_get_persist_name(s))
if (FALSE == g_hash_table_contains(self->pipes_with_persis_name, s))
{
log_pipe_ref(s);
g_hash_table_add(self->pipes_with_persis_name, s);
const gchar *persist_name = log_pipe_get_persist_name(s);
if (persist_name)
{
log_pipe_ref(s);
g_hash_table_add(self->pipes_with_persis_name, s);
msg_trace("Pipe registered", evt_tag_str("persist-name", persist_name));
}
}
}
}
Expand Down

0 comments on commit 73b4434

Please sign in to comment.