xcb_list_hosts(3)
π xcb_list_hosts β bestie, let's peek at the X server's host list π
Okay so this is a page from libxcb, the C bindings for XCB (that's the X protocol thingy that talks to your X11 server). This one's called xcb_list_hosts, and no cap, the NAME section up top is literally empty β iconic of it, honestly. The header line said xcb_list_hosts(3) and it lives in section 3 of the manual (that's the library-functions girlies), and the whole thing got generated from xproto.xml. Let's get into it π¦
β¨ SYNOPSIS β¨
First things first, you gotta pull in the header:
#include <xcb/xproto.h>
π Request function
xcb_list_hosts_cookie_t xcb_list_hosts(xcb_connection_t *conn,
(Yes, the original cuts off right there mid-signature. We don't fix it, we don't question it, we simply respect the vibe. π )
π§ Reply datastructure
typedef struct xcb_list_hosts_reply_t {
uint8_t response_type;
uint8_t mode;
uint16_t sequence;
uint32_t length;
uint16_t hosts_len;
uint8_t pad0[22];
} xcb_list_hosts_reply_t;
πΈ Reply function
xcb_list_hosts_reply_t *xcb_list_hosts_reply(xcb_connection_t *conn,
xcb_list_hosts_cookie_t cookie, xcb_generic_error_t **e);
β Reply accessors
int xcb_list_hosts_hosts_length(const xcb_list_hosts_reply_t *reply);
xcb_host_iterator_t xcb_list_hosts_hosts_iterator(const
xcb_list_hosts_reply_t *reply);
π«Ά REQUEST ARGUMENTS π«Ά
connβ The XCB connection to X11. Your lil hotline to the server, bestie. Without it we're just screaming into the void. π
π REPLY FIELDS π
response_typeβ The type of this reply, which in this case isXCB_LIST_HOSTS. This field also shows up in thexcb_generic_reply_t, so you can use it to tell your replies apart from each other. It's giving name tag at a party. π·οΈsequenceβ The sequence number of the last request processed by the X11 server. Keeping receipts, fr fr.lengthβ The length of the reply, in words. And heads up, a word here is 4 bytes. Not a vibe, just a fact. πmodeβ TODO: NOT YET DOCUMENTED. Mystery behaviour, we love that for us. πhosts_lenβ TODO: NOT YET DOCUMENTED. Also a mystery. The docs said "figure it out" and left. π
π DESCRIPTION π
Nothing here, bestie. The DESCRIPTION section is empty. Not a single word. We respect the silence. π€
π₯ RETURN VALUE π₯
Returns an xcb_list_hosts_cookie_t. Errors have to be handled when calling the reply function xcb_list_hosts_reply.
If you'd rather handle errors in the event loop instead, use xcb_list_hosts_unchecked. See xcb-requests(3) for details β that's the page that explains the whole checked/unchecked situation, iykyk.
π ERRORS π
This request does never generate any errors. Zero. Zilch. Not one. Chillest request in the whole protocol, honestly. π
π SEE ALSO π
Nothing listed. Empty. We move. πΆββοΈ
π AUTHOR π
Generated from xproto.xml. Contact xcb@lists.freedesktop.org for corrections and improvements. (So if something's off, that's who you email β be nice, they're doing their best π«Ά)
And that's the whole page, babe. This one came to you from X Version 11, libxcb 1.17.0, dated xcb_list_hosts(3) β slay, periodt, go read the header file. π β¨
π¦ where this page comes from
- alpine 3.22: libxcb-doc 1.17.0-r0 Β· MIT
- alpine 3.23: libxcb-doc 1.17.0-r1 Β· MIT
- alpine 3.24: libxcb-doc 1.17.0-r2 Β· MIT
- arch rolling: libxcb 1.17.0-1 Β· X11
- centos-stream 10: libxcb-devel 1.17.0-3.el10 Β· X11
- debian trixie: libxcb-doc 1.17.0-2
- fedora 43: libxcb-devel 1.17.0-6.fc43 Β· X11
- fedora 43: libxcb-devel 1.17.0-6.fc43 Β· X11
- fedora 44: libxcb-devel 1.17.0-7.fc44 Β· X11
- fedora 44: libxcb-devel 1.17.0-7.fc44 Β· X11
- nixpkgs unstable: libxcb 1.17.0
- opensuse-leap 16.0: libxcb-devel-doc 1.17.0-160000.2.2 Β· MIT
- ubuntu questing: libxcb-doc 1.17.0-2build1
- ubuntu resolute: libxcb-doc 1.17.0-2ubuntu1
- ubuntu stonking: libxcb-doc 1.17.0-2ubuntu1
- π girlified by deepseek-ai/DeepSeek-V4.1-Flash on : a language model's rewrite of the original, under its terms