cgiwrap_init_emu(3)
π cgiwrap_init_emu(3) π
okay so bestie, welcome to the glow-up era of cgiwrap_init_emu(3) β a function from cgi/cgiwrap.h, sitting pretty in section 3 of the manual. she's the one you call when you're not running in a real live CGI environment and you wanna fake it till you make it β¨
πΈ NAME πΈ
cgiwrap_init_emu β initialize cgiwrap for emulated use π
π SYNOPSIS π
#include <cgi/cgiwrap.h>
void cgiwrap_init_emu (void *data, READ_FUNC read_cb,
WRITEF_FUNC writef_cb, WRITE_FUNC write_cb, GETENV_FUNC getenv_cb,
PUTENV_FUNC putenv_cb, ITERENV_FUNC iterenv_cb);
π¦ ARGUMENTS π¦
dataβ your user data, hand-delivered straight to all the callbacks you're about to pass in. she's the lil bag of goodies that travels with every call πread_cbβ a cb that steps in forfread(stdin)writef_cbβ a cb that steps in forfprintf(stdout)(and yes, the original really spells it repalce β typo is canon, we do not touch it, no cap π)write_cbβ a cb that replacesfwrite(stdout)getenv_cbβ a cb that replacesgetenvputenv_cbβ a cb that replacesputenviterenv_cbβ a cb that replaces the default environment iteration function (which, for the record, just wraps walking theenvparray) πΆβοΈ
β¨ DESCRIPTION β¨
so here's the tea, bestie: cgiwrap_init_emu sets up the whole cgiwrap subsystem for use in an emulated environment β that's the kind of setup where you are the one supplying the routines that stand in for the standard ones. it's giving "when used to interface with a server or a scripting language" energy π
if you wanna see the exact definitions of those callback functions, go look at cgi/cgiwrap.h β she has the receipts π₯
π RETURN VALUE π
None. absolutely nothing. returns void, gives nothing back, keeps zero secrets π«Ά
π SEE ALSO π
cgiwrap_iterenv(3)cgiwrap_putenv(3)cgiwrap_init_emu(3)cgiwrap_writef(3)cgiwrap_init_std(3)cgiwrap_writevf(3)cgiwrap_read(3)cgiwrap_write(3)cgiwrap_getenv
that's the whole page, bestie β go forth and emulate, main character energy only π
this one came to you courtesy of ClearSilver, dated 12 July 2007 β vintage, iconic, and still serving looks. mwah ππ
π¦ where this page comes from
- debian bookworm: clearsilver-dev 0.10.5-4+b5
- debian trixie: clearsilver-dev 0.10.5-6+b1
- epel 10: clearsilver 0.10.5-80.el10_2 Β· Apache-1.1
- epel 9: clearsilver 0.10.5-74.el9 Β· Apache-1.1
- fedora 43: clearsilver 0.10.5-80.fc43 Β· Apache-1.1
- fedora 44: clearsilver 0.10.5-82.fc44 Β· Apache-1.1
- ubuntu jammy: clearsilver-dev 0.10.5-4build3
- ubuntu noble: clearsilver-dev 0.10.5-4build7
- ubuntu questing: clearsilver-dev 0.10.5-6build1
- ubuntu resolute: clearsilver-dev 0.10.5-7
- ubuntu stonking: clearsilver-dev 0.10.5-7build1
- π girlified by deepseek-ai/DeepSeek-V4.1-Flash on : a language model's rewrite of the original, under its terms