diff options
author | Brad King <brad.king@kitware.com> | 2023-05-26 13:21:53 (GMT) |
---|---|---|
committer | Kitware Robot <kwrobot@kitware.com> | 2023-05-26 13:22:09 (GMT) |
commit | 8ed8c73bd48569ced052bdfcf3249e042d203232 (patch) | |
tree | 5690062d8995f17a3d3e25e90cadb88cf9a713da /Source | |
parent | a645a80040d35162ba34ddec39b1b90b2466b72f (diff) | |
parent | 4032968220a53bbf66e38455d51ecdcdf603921d (diff) | |
download | CMake-8ed8c73bd48569ced052bdfcf3249e042d203232.zip CMake-8ed8c73bd48569ced052bdfcf3249e042d203232.tar.gz CMake-8ed8c73bd48569ced052bdfcf3249e042d203232.tar.bz2 |
Merge topic 'update-kwsys'
4032968220 Merge branch 'upstream-KWSys' into update-kwsys
5df527f7af KWSys 2023-05-25 (c9f0da47)
Acked-by: Kitware Robot <kwrobot@kitware.com>
Acked-by: buildbot <buildbot@kitware.com>
Merge-request: !8504
Diffstat (limited to 'Source')
-rw-r--r-- | Source/kwsys/SystemInformation.cxx | 4 |
1 files changed, 4 insertions, 0 deletions
diff --git a/Source/kwsys/SystemInformation.cxx b/Source/kwsys/SystemInformation.cxx index 20e2edb..7f8485e 100644 --- a/Source/kwsys/SystemInformation.cxx +++ b/Source/kwsys/SystemInformation.cxx @@ -3453,6 +3453,10 @@ bool SystemInformationImplementation::RetrieveInformationFromCpuInfoFile() fileSize++; } fclose(fd); + if (fileSize < 2) { + std::cout << "No data in /proc/cpuinfo" << std::endl; + return false; + } buffer.resize(fileSize - 2); // Number of logical CPUs (combination of multiple processors, multi-core // and SMT) |