tag = ""; // LCOV_EXCL_LINE
if (log_id >= LOG_ID_MAX ||
+ log_id < 0 ||
prio < DLOG_VERBOSE ||
prio >= DLOG_PRIO_MAX ||
!msg ||
- 1 /* priority */ + strlen(tag) + 1 /* NULL delimiter */ + strlen(msg) + 1 /* NULL terminator */ >= LOG_MAX_PAYLOAD_SIZE)
+ 1 /* priority */ + strlen(tag) + 1 /* NULL delimiter */ + strlen(msg) + 1 /* NULL terminator */ > LOG_MAX_PAYLOAD_SIZE)
return DLOG_ERROR_INVALID_PARAMETER;
create_pipe_message(buf, prio, tag, msg);
return; // LCOV_EXCL_LINE
}
+ if (conf_val[0] != '/') {
+ syslog_critical_failure("DLOG CRITICAL FAILURE: path \"%s\% from \"%s\" is not absolute!\n", conf_val, conf_key);
+ return;
+ }
+
const size_t pathlen = strlen(conf_val);
static const size_t MAX_PIPE_PATH = sizeof ((struct sockaddr_un *)NULL)->sun_path;
if (strlen(conf_val) >= MAX_PIPE_PATH) {