From 079f4c20092b91f4be503d5029d23ce141b77855 Mon Sep 17 00:00:00 2001 From: Jean-Paul Chaput Date: Tue, 11 May 2021 13:46:53 +0200 Subject: [PATCH] Fix unitialized stat structure in Vlsisapd, Path::mode() (valgrind). --- vlsisapd/src/utilities/src/Path.cpp | 10 ++++++++++ 1 file changed, 10 insertions(+) diff --git a/vlsisapd/src/utilities/src/Path.cpp b/vlsisapd/src/utilities/src/Path.cpp index 0b47c132..c7df122f 100644 --- a/vlsisapd/src/utilities/src/Path.cpp +++ b/vlsisapd/src/utilities/src/Path.cpp @@ -250,6 +250,16 @@ namespace Utilities { unsigned int Path::mode () const { struct stat bstat; + bstat.st_dev = 0; + bstat.st_ino = 0; + bstat.st_mode = 0; + bstat.st_nlink = 0; + bstat.st_uid = 0; + bstat.st_gid = 0; + bstat.st_rdev = 0; + bstat.st_size = 0; + bstat.st_blksize = 0; + bstat.st_blocks = 0; //int status = 0; //status = ::stat( toString().c_str(), &bstat );