From b7f197633a13c273f39bfff62fe3f4be92942b65 Mon Sep 17 00:00:00 2001 From: Yann Collet Date: Sat, 2 Jul 2016 00:59:25 +0200 Subject: [PATCH] use strerror(errno) to return system error message --- programs/fileio.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/programs/fileio.c b/programs/fileio.c index 83d3c61f..7d6a406e 100644 --- a/programs/fileio.c +++ b/programs/fileio.c @@ -411,7 +411,7 @@ static int FIO_compressFilename_dstFile(cRess_t ress, int result; ress.dstFile = FIO_openDstFile(dstFileName); - if (ress.dstFile==0) { DISPLAYLEVEL(1, "zstd: %s: cannot open \n", dstFileName); return 1; } + if (ress.dstFile==0) { DISPLAYLEVEL(1, "zstd: %s: %s \n", dstFileName, strerror(errno)); return 1; } result = FIO_compressFilename_srcFile(ress, dstFileName, srcFileName, cLevel);