diff options
author | Marcel Raad <Marcel.Raad@teamviewer.com> | 2019-05-12 14:35:22 +0200 |
---|---|---|
committer | Marcel Raad <Marcel.Raad@teamviewer.com> | 2019-05-20 08:06:24 +0200 |
commit | 27af2ec219244bef24e6d11649d41aad3668da45 (patch) | |
tree | e362c485f092e35b7fcb41631ace9eec56fbfeb6 | |
parent | 320cec284d142e67cdf3f6c76f3851449991d87f (diff) |
tool_formparse: remove redundant assignment
Just initialize word_begin with the correct value.
Closes https://github.com/curl/curl/pull/3873
-rw-r--r-- | src/tool_formparse.c | 5 |
1 files changed, 2 insertions, 3 deletions
diff --git a/src/tool_formparse.c b/src/tool_formparse.c index 51aebd25a..74d1533e4 100644 --- a/src/tool_formparse.c +++ b/src/tool_formparse.c @@ -347,12 +347,11 @@ CURLcode tool2curlmime(CURL *curl, tool_mime *m, curl_mime **mime) static char *get_param_word(char **str, char **end_pos, char endchar) { char *ptr = *str; - char *word_begin = NULL; + /* the first non-space char is here */ + char *word_begin = ptr; char *ptr2; char *escape = NULL; - /* the first non-space char is here */ - word_begin = ptr; if(*ptr == '"') { ++ptr; while(*ptr) { |