1---
2c: Copyright (C) Daniel Stenberg, <daniel@haxx.se>, et al.
3SPDX-License-Identifier: curl
4Title: CURLMOPT_CHUNK_LENGTH_PENALTY_SIZE
5Section: 3
6Source: libcurl
7See-also:
8  - CURLMOPT_CONTENT_LENGTH_PENALTY_SIZE (3)
9  - CURLMOPT_MAX_PIPELINE_LENGTH (3)
10  - CURLMOPT_PIPELINING (3)
11Protocol:
12  - HTTP
13Added-in: 7.30.0
14---
15
16# NAME
17
18CURLMOPT_CHUNK_LENGTH_PENALTY_SIZE - chunk length threshold for pipelining
19
20# SYNOPSIS
21
22~~~c
23#include <curl/curl.h>
24
25CURLMcode curl_multi_setopt(CURLM *handle, CURLMOPT_CHUNK_LENGTH_PENALTY_SIZE,
26                            long size);
27~~~
28
29# DESCRIPTION
30
31No function since pipelining was removed in 7.62.0.
32
33Pass a long with a **size** in bytes. If a transfer in a pipeline is
34currently processing a chunked (Transfer-encoding: chunked) request with a
35current chunk length larger than CURLMOPT_CHUNK_LENGTH_PENALTY_SIZE(3),
36that pipeline is not considered for additional requests, even if it is shorter
37than CURLMOPT_MAX_PIPELINE_LENGTH(3).
38
39# DEFAULT
40
410, which means that penalization is inactive.
42
43# %PROTOCOLS%
44
45# EXAMPLE
46
47~~~c
48int main(void)
49{
50  CURLM *m = curl_multi_init();
51  long maxchunk = 10000;
52  curl_multi_setopt(m, CURLMOPT_CHUNK_LENGTH_PENALTY_SIZE, maxchunk);
53}
54~~~
55
56# %AVAILABILITY%
57
58# RETURN VALUE
59
60Returns CURLM_OK if the option is supported, and CURLM_UNKNOWN_OPTION if not.
61