summaryrefslogtreecommitdiff
path: root/src
diff options
context:
space:
mode:
authorJay Satiro <raysatiro@yahoo.com>2020-06-26 02:26:41 -0400
committerJay Satiro <raysatiro@yahoo.com>2020-06-26 09:48:58 -0400
commitcb8527537788a33df245283206b71c807af21c5d (patch)
tree259bfd473bd2b36d6fc311d119c7e28f25488e8a /src
parent43f7ffb6c4c1d63815ed2fcc5799bed9f7d96033 (diff)
downloadcurl-cb8527537788a33df245283206b71c807af21c5d.tar.gz
tool_cb_hdr: Fix etag warning output and return code
- Return 'failure' on failure, to follow the existing style. - Put Warning: and the warning message on the same line. Ref: https://github.com/curl/curl/issues/5610 Closes https://github.com/curl/curl/pull/5612
Diffstat (limited to 'src')
-rw-r--r--src/tool_cb_hdr.c8
1 files changed, 4 insertions, 4 deletions
diff --git a/src/tool_cb_hdr.c b/src/tool_cb_hdr.c
index b80707fde..5741f0aba 100644
--- a/src/tool_cb_hdr.c
+++ b/src/tool_cb_hdr.c
@@ -119,8 +119,8 @@ size_t tool_header_cb(char *ptr, size_t size, size_t nmemb, void *userdata)
if(!first) {
warnf(per->config->global,
- "\nReceived header etag is missing double quote/s\n");
- return 1;
+ "Received header etag is missing double quote/s\n");
+ return failure;
}
else {
/* discard first double quote */
@@ -132,8 +132,8 @@ size_t tool_header_cb(char *ptr, size_t size, size_t nmemb, void *userdata)
if(!last) {
warnf(per->config->global,
- "\nReceived header etag is missing double quote/s\n");
- return 1;
+ "Received header etag is missing double quote/s\n");
+ return failure;
}
/* get length of desired etag */