]> git.ipfire.org Git - thirdparty/curl.git/commitdiff
curl_url_set.3: properly escape \n in example code
authorDave Reisner <dreisner@archlinux.org>
Mon, 10 Sep 2018 13:39:33 +0000 (09:39 -0400)
committerDaniel Stenberg <daniel@haxx.se>
Thu, 13 Sep 2018 06:07:36 +0000 (08:07 +0200)
This yields

  "the scheme is %s\n"

instead of

  "the scheme is %s0

Closes #2970

docs/libcurl/curl_url_get.3

index b1313eae2806a89a38031a592aba4736e4124bfb..53f7954feaa3536070da0338e97b8a445c6424a2 100644 (file)
@@ -97,7 +97,7 @@ If this function returns an error, no URL part is returned.
     char *scheme;
     rc = curl_url_get(url, CURLUPART_SCHEME, &scheme, 0);
     if(!rc) {
-      printf("the scheme is %s\n", scheme);
+      printf("the scheme is %s\\n", scheme);
       curl_free(scheme);
     }
     curl_url_cleanup(url);