From aff70e2e9534eecb9e756d2104efa52e5d8b0462 Mon Sep 17 00:00:00 2001 From: warp kawada Date: Thu, 8 Sep 2011 15:39:39 -0700 Subject: Curl_add_custom_headers: support headers with no data A custom HTTP header ending in a semicolon instead of a colon will be treated as a header to be added without any data portion. --- docs/curl.1 | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) (limited to 'docs') diff --git a/docs/curl.1 b/docs/curl.1 index d6fb9aa22..45e9f52ae 100644 --- a/docs/curl.1 +++ b/docs/curl.1 @@ -592,7 +592,9 @@ header will be used instead of the internal one. This allows you to make even trickier stuff than curl would normally do. You should not replace internally set headers without knowing perfectly well what you're doing. Remove an internal header by giving a replacement without content on the right side of -the colon, as in: -H \&"Host:". +the colon, as in: -H \&"Host:". If you send the custom header with no-value then +its header must be terminated with a semicolon, such as \-H "X-Custom-Header;" +to send "X-Custom-Header:". curl will make sure that each header you add/replace is sent with the proper end-of-line marker, you should thus \fBnot\fP add that as a part of the header -- cgit v1.2.3