DMMP_CONTEXT_LOG_PRIORITY_SET(3)
π dmmp_context_log_priority_set(3) π
okay bestie, so this is a page from the libdmmp manual β that's the Device Mapper Multipath API β and we're gonna talk about the little function that controls how chatty your logs are. it's giving "volume knob but for logging". obsessed. π
β¨ NAME β¨
dmmp_context_log_priority_set β set log priority, bestie. that's it. that's the whole job. π
πΈ SYNOPSIS πΈ
void dmmp_context_log_priority_set (struct dmmp_context *ctx, int priority);
π¦ ARGUMENTS π¦
ctxβ a pointer tostruct dmmp_context. and listen, if this pointer isNULL?? π your program is gonna get terminated by assert. no cap. not a vibe. don't do it.priorityβ anint, and it's your log priority. that's the whole thing. π«Ά
π DESCRIPTION π
so when the library generates a log message, only the messages that are equal to or more important (and by "more important" we mean less value, yes the numbers go backwards, iykyk) get forwarded to the log handler function. so like, the priority you set is the floor β anything less important than that just does not make it through. gatekeeping, honestly. π
here are the valid log priority values, and yes you're getting the whole list because we don't skip:
DMMP_LOG_PRIORITY_ERROR--3DMMP_LOG_PRIORITY_WARNING--4DMMP_LOG_PRIORITY_INFO--5DMMP_LOG_PRIORITY_DEBUG--7
so if you set it to 7 (DMMP_LOG_PRIORITY_DEBUG) you're getting everything, main character energy, all the lore. if you set it to 3 (DMMP_LOG_PRIORITY_ERROR) you're only hearing about the drama. pick your fighter. π₯
π RETURN π
void
like, it returns nothing. literally nothing. it's just out here doing its thing and not reporting back. respect. π
and that's the page!! this one came from the June 2025 release of the libdmmp manual, and the footer tag on it is dmmp_context_log_priority_set / dmmp_...ty_set(3) β the truncated little header situation, we love a mystery. π§
stay logged, stay prioritized, and pls pls pls don't pass a NULL ctx. mwah. πβ¨πΈ
π¦ where this page comes from
- arch rolling: multipath-tools 0.15.1-1 Β· GPL-2.0-or-later AND GPL-3.0-or-later AND LGPL-2.0-or-later AND LGPL-2.1-or-later
- fedora 44: libdmmp-devel 0.13.1-1.fc44 Β· GPL-2.0-only AND GPL-3.0-only
- fedora 44: libdmmp-devel 0.13.1-1.fc44 Β· GPL-2.0-only AND GPL-3.0-only
- nixos 26.05: multipath-tools 0.14.1
- nixpkgs unstable: multipath-tools 0.14.3
- opensuse-leap 16.0: libdmmp-devel 0.12.4+278+suse.9cf9c5c-160000.1.1 Β· GPL-3.0-or-later
- opensuse-leap 16.0: libdmmp-devel 0.12.4+278+suse.9cf9c5c-160000.1.1 Β· GPL-3.0-or-later
- opensuse-leap 16.0: libdmmp-devel 0.12.4+278+suse.9cf9c5c-160000.1.1 Β· GPL-3.0-or-later
- opensuse-leap 16.0: libdmmp-devel 0.12.4+278+suse.9cf9c5c-160000.1.1 Β· GPL-3.0-or-later
- π girlified by deepseek-ai/DeepSeek-V4.1-Flash on : a language model's rewrite of the original, under its terms