]> git.ipfire.org Git - thirdparty/zstd.git/commitdiff
update error message 4349/head
authorYann Collet <cyan@fb.com>
Fri, 28 Mar 2025 17:02:37 +0000 (10:02 -0700)
committerYann Collet <cyan@fb.com>
Fri, 28 Mar 2025 17:02:37 +0000 (10:02 -0700)
programs/fileio.c
tests/cli-tests/file-stat/compress-file-to-dir-without-write-perm.sh.stderr.exact

index 6c6faa485697d988001d4d2e6bc48af1f33dd71a..dc7636949725558aeebd0836886981345a57163e 100644 (file)
@@ -659,9 +659,10 @@ FIO_openDstFile(FIO_ctx_t* fCtx, FIO_prefs_t* const prefs,
         }
 #endif
         if (f == NULL) {
-            DISPLAYLEVEL(1, "zstd: %s: %s\n", dstFileName, strerror(errno));
             if (UTIL_isFileDescriptorPipe(dstFileName)) {
-                DISPLAYLEVEL(1, "When using process substitution (<(...)), specify an output destination with -o or -c. \n");
+                DISPLAYLEVEL(1, "zstd: error: no output specified (use -o or -c). \n");
+            } else {
+                DISPLAYLEVEL(1, "zstd: %s: %s\n", dstFileName, strerror(errno));
             }
         } else {
             /* An increased buffer size can provide a significant performance
index 515b63c60a1cecfaefb1fcc1e0ead7efe7df0402..9f254f8c25e4dc33ad3d4e40916e50e9a28b103e 100644 (file)
@@ -22,7 +22,7 @@ Trace:FileStat: > UTIL_isRegularFile(out/file.zst)
 Trace:FileStat:  > UTIL_stat(-1, out/file.zst)
 Trace:FileStat:  < 0
 Trace:FileStat: < 0
-zstd: out/file.zst: Permission denied
 Trace:FileStat: > UTIL_isFileDescriptorPipe(out/file.zst)
 Trace:FileStat: < 0
+zstd: out/file.zst: Permission denied
 zstd: can't stat out/file.zst : Permission denied -- ignored