DMMP_CONTEXT_LOG_PRIORITY_SET(3)

πŸ“¦
version 0.15.1 Β· 3 versions
, in arch rolling, fedora 44, nixos 26.05, nixpkgs unstable, opensuse-leap 16.0

πŸ’– 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 to struct dmmp_context. and listen, if this pointer is NULL?? 😭 your program is gonna get terminated by assert. no cap. not a vibe. don't do it.
  • priority β€” an int, 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 -- 3
  • DMMP_LOG_PRIORITY_WARNING -- 4
  • DMMP_LOG_PRIORITY_INFO -- 5
  • DMMP_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. πŸ’–βœ¨πŸŒΈ