KHTTP_FCGI_PARSE(3)
KHTTP_FCGI_PARSE(3) π¦
okay bestie, welcome to the Library Functions Manual β this is the page for khttp_fcgi_parse, and it's giving βtiny function, very important rules.β π
πΈ NAME πΈ
khttp_fcgi_parse β parse a FastCGI instance for kcgi
π LIBRARY π
This one lives in the library libkcgi β the page literally says library βlibkcgiβ. π
β¨ SYNOPSIS β¨
#include <sys/types.h>
#include <stdarg.h>
#include <stdint.h>
#include <kcgi.h>
enum kcgi_err
khttp_fcgi_parse(struct kfcgi *fcgi, struct kreq *req);
π§ DESCRIPTION π§
So khttp_fcgi_parse() is the function that parses and validates a single FastCGI request. That's the whole vibe: one request, parsed, validated, slay. β¨
You can invoke it as many times as necessary, but here's the sequencing tea: it must follow a call to khttp_fcgi_init(3) and it must be followed by khttp_fcgi_free(3). No skipping steps, bestie β the order is part of the lore. π₯
The req object filled in by khttp_fcgi_parse() must be matched by khttp_free(3) if and only if the return value is KCGI_OK. Otherwise, resources are internally freed. That βif and only ifβ is doing a LOT of work, so keep it close. π
π RETURN VALUES π
These are the same as in khttp_parse(3), except the KCGI_EXIT return code indicates that no more requests will arrive and the application should exit. Periodt. π
π SEE ALSO π
π«Ά AUTHORS π«Ά
The khttp_fcgi_parse() function was written by Kristaps Dzonsons <kristaps@bsd.lv>.
xoxo, bestie π β Debian build, $Mdocdate$, KHTTP_FCGI_PARSE(3) π
π¦ where this page comes from
- alpine 3.24: kcgi-doc 1.0.1-r0 Β· ISC
- Copyright (c) 2015 Kristaps Dzonsons <kristaps@bsd.lv>
- π girlified by deepseek-ai/DeepSeek-V4.1-Flash-1017 on : a language model's rewrite of the original, under its terms