This is sometimes needed for integration tests to work.
Change-Id: I5c829b45442276982d053111142bb87e998d4712
if (r < 0)
return r;
+ // This matches what log.c does.
+ bool plog = buffer == LOG_ID_APPS ? true : log_config_get_boolean(&config, "plog", true);
+ char key[MAX_CONF_KEY_LEN];
+ r = snprintf(key, sizeof key, "enable_%s", log_name_by_id(buffer));
+ if (r < 0)
+ return r;
+ plog = log_config_get_boolean(&config, key, plog);
+ if (!plog)
+ return -EPERM;
+
const char *const backend = log_config_claim_backend(&config);
if (!backend)
return -ENOKEY;