Date: Mon, 5 Mar 2018 20:03:45 +0000 (UTC) From: Conrad Meyer <cem@FreeBSD.org> To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-head@freebsd.org Subject: svn commit: r330521 - head/sys/contrib/zstd/programs Message-ID: <201803052003.w25K3jdH069457@repo.freebsd.org>
next in thread | raw e-mail | index | archive | help
Author: cem Date: Mon Mar 5 20:03:45 2018 New Revision: 330521 URL: https://svnweb.freebsd.org/changeset/base/330521 Log: MFV: zstd: FIO_addFInfo: Fully initialize output 'total' struct Silence a Coverity warning about 'windowSize' being uninitialized. (Yes, nothing that calls this routine actually uses the windowSize value. Still, appeasing Coverity is pretty harmless in this case.) Reported by: Coverity Reviewed by: Yann Collet Obtained from: zstd 606374269cf3485972c90b993fbb84dc20da032f Sponsored by: Dell EMC Isilon Modified: head/sys/contrib/zstd/programs/fileio.c Modified: head/sys/contrib/zstd/programs/fileio.c ============================================================================== --- head/sys/contrib/zstd/programs/fileio.c Mon Mar 5 19:02:32 2018 (r330520) +++ head/sys/contrib/zstd/programs/fileio.c Mon Mar 5 20:03:45 2018 (r330521) @@ -1971,6 +1971,7 @@ static void displayInfo(const char* inFileName, fileIn static fileInfo_t FIO_addFInfo(fileInfo_t fi1, fileInfo_t fi2) { fileInfo_t total; + memset(&total, 0, sizeof(total)); total.numActualFrames = fi1.numActualFrames + fi2.numActualFrames; total.numSkippableFrames = fi1.numSkippableFrames + fi2.numSkippableFrames; total.compressedSize = fi1.compressedSize + fi2.compressedSize;
Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?201803052003.w25K3jdH069457>