spa: use log topics everywhere

Use log topics properly everywhere, convert from "#define NAME".
This commit is contained in:
Pauli Virtanen 2024-03-10 17:32:56 +02:00
parent c963ca47c1
commit e784de3933
27 changed files with 170 additions and 102 deletions

View file

@ -24,7 +24,9 @@
#define CLOCK_MONOTONIC_RAW CLOCK_MONOTONIC
#endif
#define NAME "logger"
#undef SPA_LOG_TOPIC_DEFAULT
#define SPA_LOG_TOPIC_DEFAULT &log_topic
SPA_LOG_TOPIC_DEFINE_STATIC(log_topic, "spa.logger");
#define DEFAULT_LOG_LEVEL SPA_LOG_LEVEL_INFO
@ -357,7 +359,7 @@ impl_init(const struct spa_handle_factory *factory,
spa_ringbuffer_init(&this->trace_rb);
spa_log_debug(&this->log, NAME " %p: initialized to %s linebuf:%u", this, dest, linebuf);
spa_log_debug(&this->log, "%p: initialized to %s linebuf:%u", this, dest, linebuf);
return 0;
}