C Collections

clogger · Section 3

clog_remove_field

clog_remove_field - remove a previously attached structured field

C Collections (libccollections, -lccollections)

#include <ccollections/clogger.h>
 
void clog_remove_field(clog logger, const char *key);

Removes the field with the given key from the field list of the logger,
so the field appears in no later log line.  When the field list holds no
such key the call does nothing.

logger  Logger handle.
key     Field name to remove. The match is exact and case-sensitive.

Thread-safe, because the mutex of the logger protects the call.
Asserts when logger is CLOG_NULL, stale or already closed.

clog_set_field(3), clog_clear_fields(3)