shishi_init_server(3)

πŸ“¦
version 1.0.3 Β· 2 versions
  • 1.0.3 Β· debian bookworm, debian trixie, nixos 26.05, nixpkgs unstable, ubuntu noble, ubuntu questing, ubuntu resolute, ubuntu stonking (latest)
  • 1.0.2 Β· ubuntu jammy
, in debian bookworm, debian trixie, nixos 26.05, nixpkgs unstable, ubuntu noble, ubuntu questing, ubuntu resolute, ubuntu stonking

✨ shishi_init_server β€” the manual page, bestie edition ✨

okay so real talk, this is shishi_init_server(3) from the shishi manual, section 3 (that's the library-functions section, iykyk). it's giving "let me set you up with a handle". 🫢


🌸 NAME 🌸

shishi_init_server β€” an API function. that's it, that's the name. short, sweet, main character energy. πŸ’…


πŸŽ€ SYNOPSIS πŸŽ€

#include <shishi.h>

int shishi_init_server(Shishi ** handle);

literally just include the header and call the thing. periodt.


πŸ¦‹ ARGUMENTS πŸ¦‹

  • Shishi ** handle β€” a pointer to a Shishi handle, and guess what, that handle gets created by this very call. it's a pointer-to-a-pointer situation, so yes, we're going two levels deep. she's ambitious like that. ✨

πŸ’– DESCRIPTION πŸ’–

okay so here's the tea: this function creates a Shishi library handle by calling shishi_server(), and then it reads the system configuration file. πŸ“

where does it find that config file, you ask? the path is decided at compile time, bestie β€” it's baked in, no take-backs. the path is $sysconfdir/shishi.conf. iconic.

and here's the important part, don't skip this: the handle is allocated regardless of the return value. yes, even if stuff goes wrong, the handle still exists. the single exception is SHISHI_HANDLE_ERROR, which means there was a problem actually allocating the handle β€” that's the one case where things are truly not okay. 😭

other error conditions? yeah, those could pop up while it's reading the file. so like, allocate = basically always, read-the-file = could be messy. πŸ’€


⭐ RETURN VALUE ⭐

returns SHISHI_OK iff successful. that "iff" is doing heavy lifting β€” it means if and only if, no vibes-based grading here. ✨


πŸ™ˆ REPORTING BUGS πŸ™ˆ

found a bug? not me gatekeeping β€” report it to <bug-shishi@gnu.org>. πŸ’œ


Copyright Β© 2002-2022 Simon Josefsson.

Copying and distribution of this file, with or without modification, are permitted in any medium without royalty provided the copyright notice and this notice are preserved.

(translation: go off, copy it, remix it, just keep the receipts. πŸŽ€)


🌈 SEE ALSO 🌈

The full documentation for shishi is maintained as a Texinfo manual. If the info and shishi programs are properly installed at your site, the command

info shishi

should give you access to the complete manual. that's the whole manual, the director's cut, the extended edition. go read it. 🧚


and that's the page, bestie! this was shishi_init_server(3), from shishi version 1.0.3. slay, stay configured, and don't forget to free your handles. mwah πŸ’…πŸ’–