Skip to content
This repository

HTTPS clone URL

Subversion checkout URL

You can clone with HTTPS or Subversion.

Download ZIP
Browse code

document the double-quote and backslash need be escaped if quoting.

  • Loading branch information...
commit 81ea8277ef3c9b5333e82873f0e457ff3b17a252 1 parent fcca552
ulion authored

Showing 2 changed files with 5 additions and 1 deletion. Show diff stats Hide diff stats

  1. +3 0  docs/curl.1
  2. +2 1  src/tool_formparse.c
3  docs/curl.1
@@ -492,6 +492,9 @@ or
492 492
493 493 \fBcurl\fP -F 'file=@"localfile";filename="nameinpost"' url.com
494 494
  495 +Note that if a filename/path is quoted by double-quotes, any double-quote
  496 +or backslash within the filename must be escaped by backslash.
  497 +
495 498 See further examples and details in the MANUAL.
496 499
497 500 This option can be used multiple times.
3  src/tool_formparse.c
@@ -133,7 +133,8 @@ char *get_param_word(char **str, char **end_pos)
133 133 * 'name=@filename;filename="play, play, and play.txt"'
134 134 *
135 135 * If filename/path contains ',' or ';', it must be quoted by double-quotes,
136   - * else curl will fail to figure out the correct filename.
  136 + * else curl will fail to figure out the correct filename. if the filename
  137 + * tobe quoted contains '"' or '\', '"' and '\' must be escaped by backslash.
137 138 *
138 139 * This function uses curl_formadd to fulfill it's job. Is heavily based on
139 140 * the old curl_formparse code.

0 comments on commit 81ea827

Please sign in to comment.
Something went wrong with that request. Please try again.