diff options
Diffstat (limited to 'src/libtipidee/tipidee_fcgi_header_pack.c')
| -rw-r--r-- | src/libtipidee/tipidee_fcgi_header_pack.c | 15 |
1 files changed, 15 insertions, 0 deletions
diff --git a/src/libtipidee/tipidee_fcgi_header_pack.c b/src/libtipidee/tipidee_fcgi_header_pack.c new file mode 100644 index 0000000..2f1a550 --- /dev/null +++ b/src/libtipidee/tipidee_fcgi_header_pack.c @@ -0,0 +1,15 @@ +/* ISC license. */ + +#include <skalibs/uint16.h> + +#include <tipidee/fcgi.h> + +void tipidee_fcgi_header_pack (char *s, fcgi_header const *hdr) +{ + *s++ = hdr->version ; + *s++ = hdr->type ; + uint16_pack_big(s, hdr->requestid) ; s += 2 ; + uint16_pack_big(s, hdr->len) ; s += 2 ; + *s++ = hdr->padlen ; + *s++ = 0 ; +} |
