From: David Lam Date: Sat, 13 Aug 2016 18:26:21 +0000 (-0700) Subject: Remove truncation of filename in zstd CLI log lines X-Git-Tag: v0.8.1^2~7^2 X-Git-Url: http://git.ipfire.org/cgi-bin/gitweb.cgi?a=commitdiff_plain;h=refs%2Fpull%2F290%2Fhead;p=thirdparty%2Fzstd.git Remove truncation of filename in zstd CLI log lines --- diff --git a/programs/fileio.c b/programs/fileio.c index b04ee3b04..ca75e3224 100644 --- a/programs/fileio.c +++ b/programs/fileio.c @@ -364,9 +364,8 @@ static int FIO_compressFilename_internal(cRess_t ress, } /* Status */ - if (strlen(srcFileName) > 20) srcFileName += strlen(srcFileName)-20; /* display last 20 characters */ DISPLAYLEVEL(2, "\r%79s\r", ""); - DISPLAYLEVEL(2,"%-20.20s :%6.2f%% (%6llu => %6llu bytes, %s) \n", srcFileName, + DISPLAYLEVEL(2,"%-20s :%6.2f%% (%6llu => %6llu bytes, %s) \n", srcFileName, (double)compressedfilesize/(readsize+(!readsize) /* avoid div by zero */ )*100, (unsigned long long)readsize, (unsigned long long) compressedfilesize, dstFileName);