diff options
author | Daniel Stenberg <daniel@haxx.se> | 2021-01-26 17:02:39 +0100 |
---|---|---|
committer | Daniel Stenberg <daniel@haxx.se> | 2021-01-26 17:03:22 +0100 |
commit | 4fcba29031c6e7ceb87f8bd3a016a1f490ed2703 (patch) | |
tree | c71c5045d59769047134ffe549ae1572ae3bbe13 | |
parent | 6717ca020732dbaea4d7ddef0ecac13969496a70 (diff) | |
download | curl-4fcba29031c6e7ceb87f8bd3a016a1f490ed2703.tar.gz |
curl: include the file name in --xattr/--remote-time error msgsbagder/fprintf2warnf
-rw-r--r-- | src/tool_filetime.c | 4 | ||||
-rw-r--r-- | src/tool_operate.c | 4 |
2 files changed, 4 insertions, 4 deletions
diff --git a/src/tool_filetime.c b/src/tool_filetime.c index 72798dbdb..e31fd5914 100644 --- a/src/tool_filetime.c +++ b/src/tool_filetime.c @@ -140,7 +140,7 @@ void setfiletime(curl_off_t filetime, const char *filename, times[0].tv_usec = times[1].tv_usec = 0; if(utimes(filename, times)) { warnf(global, "Failed to set filetime %" CURL_FORMAT_CURL_OFF_T - " on outfile: %s\n", filetime, strerror(errno)); + " on '%s': %s\n", filetime, filename, strerror(errno)); } #elif defined(HAVE_UTIME) @@ -149,7 +149,7 @@ void setfiletime(curl_off_t filetime, const char *filename, times.modtime = (time_t)filetime; if(utime(filename, ×)) { warnf(global, "Failed to set filetime %" CURL_FORMAT_CURL_OFF_T - " on outfile: %s\n", filetime, strerror(errno)); + " on '%s': %s\n", filetime, filename, strerror(errno)); } #endif } diff --git a/src/tool_operate.c b/src/tool_operate.c index 457633a06..ae8a4f2ed 100644 --- a/src/tool_operate.c +++ b/src/tool_operate.c @@ -374,8 +374,8 @@ static CURLcode post_per_transfer(struct GlobalConfig *global, if(!result && config->xattr && outs->fopened && outs->stream) { int rc = fwrite_xattr(curl, fileno(outs->stream)); if(rc) - warnf(config->global, "Error setting extended attributes: %s\n", - strerror(errno)); + warnf(config->global, "Error setting extended attributes on '%s': %s\n", + outs->filename, strerror(errno)); } if(!result && !outs->stream && !outs->bytes) { |