]> git.ipfire.org Git - thirdparty/curl.git/commitdiff
curl_mime_headers.3: fix the example's use of curl_slist_append
authorDaniel Stenberg <daniel@haxx.se>
Tue, 8 Sep 2020 15:25:27 +0000 (17:25 +0200)
committerDaniel Stenberg <daniel@haxx.se>
Tue, 8 Sep 2020 20:51:16 +0000 (22:51 +0200)
Reported-by: sofaboss on github
Fixes #5942
Closes #5943

docs/libcurl/curl_mime_headers.3

index 1d02e1ee5d0cda71bc96d981c9f962b4e26b567f..15ccafea854a1c0b34e7a0f910589f1af9e9e8fa 100644 (file)
@@ -5,7 +5,7 @@
 .\" *                            | (__| |_| |  _ <| |___
 .\" *                             \___|\___/|_| \_\_____|
 .\" *
-.\" * Copyright (C) 1998 - 2017, Daniel Stenberg, <daniel@haxx.se>, et al.
+.\" * Copyright (C) 1998 - 2020, Daniel Stenberg, <daniel@haxx.se>, et al.
 .\" *
 .\" * This software is licensed as described in the file COPYING, which
 .\" * you should have received as part of this distribution. The terms
@@ -50,7 +50,7 @@ CURLE_OK or a CURL error code upon failure.
 .nf
  struct curl_slist *headers = NULL;
 
- headers = curl_slist_append("Custom-Header: mooo", headers);
+ headers = curl_slist_append(headers, "Custom-Header: mooo");
 
  /* use these headers, please take ownership */
  curl_mime_headers(part, headers, TRUE);