mirror of
https://gitlab.freedesktop.org/pipewire/pipewire.git
synced 2026-02-16 22:05:31 -05:00
pipewire: use local real time timestamps in logging
Wireplumber and other system services use local real time timestamps in logging, so it's more convenient if also PW uses them. Add env var for selecting the timestamp type, default to "local".
This commit is contained in:
parent
1ec814977c
commit
08700a9eb5
2 changed files with 8 additions and 1 deletions
|
|
@ -533,7 +533,10 @@ void pw_init(int *argc, char **argv[])
|
|||
str = "true";
|
||||
items[n_items++] = SPA_DICT_ITEM_INIT(SPA_KEY_LOG_COLORS, str);
|
||||
}
|
||||
items[n_items++] = SPA_DICT_ITEM_INIT(SPA_KEY_LOG_TIMESTAMP, "true");
|
||||
if ((str = getenv("PIPEWIRE_LOG_TIMESTAMP")) != NULL)
|
||||
items[n_items++] = SPA_DICT_ITEM_INIT(SPA_KEY_LOG_TIMESTAMP, str);
|
||||
else
|
||||
items[n_items++] = SPA_DICT_ITEM_INIT(SPA_KEY_LOG_TIMESTAMP, "local");
|
||||
if ((str = getenv("PIPEWIRE_LOG_LINE")) == NULL || spa_atob(str))
|
||||
items[n_items++] = SPA_DICT_ITEM_INIT(SPA_KEY_LOG_LINE, "true");
|
||||
snprintf(level, sizeof(level), "%d", pw_log_level);
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue