KWSys 2024-10-25 (7cff32e1)

Code extracted from:

    https://gitlab.kitware.com/utils/kwsys.git

at commit 7cff32e10e2bfe763415bc550816e8a9608e5954 (master).

Upstream Shortlog
-----------------

Brad King (1):
      6e847d08 SystemInformation: Add missing EOF check when reading /proc/cpuinfo
This commit is contained in:
KWSys Upstream
2024-10-25 08:46:27 -04:00
committed by Brad King
parent ede7f2afa6
commit acade348a7
+3 -2
View File
@@ -3405,8 +3405,9 @@ bool SystemInformationImplementation::RetrieveInformationFromCpuInfoFile()
}
size_t fileSize = 0;
while (!feof(fd)) {
buffer += static_cast<char>(fgetc(fd));
int fc;
while ((fc = fgetc(fd)) != EOF) {
buffer += static_cast<char>(fc);
fileSize++;
}
fclose(fd);