SD_BUS_MESSAGE_SKIP(3)
π SD_BUS_MESSAGE_SKIP(3) β the manual page, bestie edition π
okay so this is the sd_bus_message_skip page from the sd_bus_message_skip manual, and no cap, it's about skipping stuff in a bus message. stay with me, it's actually iconic β¨
πΈ NAME πΈ
sd_bus_message_skip β skip elements in a bus message π¨
π¦ SYNOPSIS π¦
#include <systemd/sd-bus.h>
int sd_bus_message_skip(sd_bus_message *m, const char* types);
β¨ DESCRIPTION β¨
so sd_bus_message_skip() is lowkey giving sd_bus_message_read(3), but here's the twist: instead of actually reading the contents of the message, it only moves the "read pointer". that's it. that's the whole vibe π«Ά
the way that means subsequent read operations will read the elements that come after the ones you skipped. so you're basically telling the message "nah, we're not doing that part, moving on" π
the types argument has the same meaning as in sd_bus_message_read(). it may also be NULL, which skips a single element of any type. versatile queen π
π₯ RETURN VALUE π₯
on success, sd_bus_message_skip() returns 0 or a positive integer. on failure, it returns a negative errno-style error code. simple as that, periodt π
π Errors π
the errors it might throw back at you mean the following things, fr fr:
-EINVALβ themparameter isNULL. you gave it nothing, bestie, what did you expect π«-EBADMSGβ the message cannot be parsed. it's giving unreadable π¬-EPERMβ the message is not sealed. nope, not allowed, sorry π€-ENXIOβ the message end has been reached and the requested elements cannot be read. you ran out of message, babe π-ENOMEMβ memory allocation failed. the computer is out of room π
π NOTES π
okay important stuff, don't skip this part (ironic, i know) π
functions described here are available as a shared library, which can be compiled against and linked to with the libsystemd pkg-config(1) file. slay, linking is handled πΈ
all functions listed here are thread-agnostic, and only a single thread may operate on a given object at any given time. different threads may access the same object at different times. multiple independent objects may be used from different threads in parallel. basically: share the object, but not at the same exact moment, iykyk π
the code described here usesgetenv(3), which is declared to be not multi-thread-safe. this means the code calling the functions described here must not callsetenv(3)from a parallel thread. it is recommended to only do calls tosetenv()from an early phase of the program when no other threads have been started. so like... do yoursetenv()era first, before the threads show up, okay? π
π§ HISTORY π§
sd_bus_message_skip() was added in version 240. a whole era π₯
π SEE ALSO π
go read those too, bestie, they're all part of the same friend group π«Ά
and that's the page!! brought to you by systemd 261.3, with the manual name SD_BUS_MESSAGE_SKIP(3) folded in right at the top like a little crown πβ¨ mwah, love you, go skip some message elements responsibly πππ¦
π¦ where this page comes from
- ubuntu stonking: libsystemd-dev 261.3-0ubuntu3 Β· LGPL-2.1-or-later
- π girlified by deepseek-ai/DeepSeek-V4.1-Flash-1017 on : a language model's rewrite of the original, under its terms