mirror of
https://github.com/moparisthebest/curl
synced 2025-01-12 06:28:04 -05:00
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
This commit is contained in:
parent
43f7ffb6c4
commit
cb85275377
@ -119,8 +119,8 @@ size_t tool_header_cb(char *ptr, size_t size, size_t nmemb, void *userdata)
|
|||||||
|
|
||||||
if(!first) {
|
if(!first) {
|
||||||
warnf(per->config->global,
|
warnf(per->config->global,
|
||||||
"\nReceived header etag is missing double quote/s\n");
|
"Received header etag is missing double quote/s\n");
|
||||||
return 1;
|
return failure;
|
||||||
}
|
}
|
||||||
else {
|
else {
|
||||||
/* discard first double quote */
|
/* 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) {
|
if(!last) {
|
||||||
warnf(per->config->global,
|
warnf(per->config->global,
|
||||||
"\nReceived header etag is missing double quote/s\n");
|
"Received header etag is missing double quote/s\n");
|
||||||
return 1;
|
return failure;
|
||||||
}
|
}
|
||||||
|
|
||||||
/* get length of desired etag */
|
/* get length of desired etag */
|
||||||
|
Loading…
Reference in New Issue
Block a user