first commit
CI / Build (clang, clang++, ubuntu-22.04, linux, 3.10, master, x86,x86_64) (push) Canceled after 0s
CI / Build (clang, clang++, windows-2022, windows, 3.10, master, x86,x86_64) (push) Canceled after 0s
CI / Release (push) Canceled after 0s

This commit is contained in:
2026-09-13 22:18:11 +01:00
commit 08c03ac533
6701 changed files with 1577314 additions and 0 deletions
+35
View File
@@ -0,0 +1,35 @@
nghttp2_hd_deflate_hd
=====================
Synopsis
--------
*#include <nghttp2/nghttp2.h>*
.. function:: ssize_t nghttp2_hd_deflate_hd(nghttp2_hd_deflater *deflater, uint8_t *buf, size_t buflen, const nghttp2_nv *nva, size_t nvlen)
Deflates the *nva*, which has the *nvlen* name/value pairs, into
the *buf* of length *buflen*.
If *buf* is not large enough to store the deflated header block,
this function fails with
:macro:`nghttp2_error.NGHTTP2_ERR_INSUFF_BUFSIZE`. The caller
should use `nghttp2_hd_deflate_bound()` to know the upper bound of
buffer size required to deflate given header name/value pairs.
Once this function fails, subsequent call of this function always
returns :macro:`nghttp2_error.NGHTTP2_ERR_HEADER_COMP`.
After this function returns, it is safe to delete the *nva*.
This function returns the number of bytes written to *buf* if it
succeeds, or one of the following negative error codes:
:macro:`nghttp2_error.NGHTTP2_ERR_NOMEM`
Out of memory.
:macro:`nghttp2_error.NGHTTP2_ERR_HEADER_COMP`
Deflation process has failed.
:macro:`nghttp2_error.NGHTTP2_ERR_INSUFF_BUFSIZE`
The provided *buflen* size is too small to hold the output.