diff options
author | Luis Ibanez <luis.ibanez@kitware.com> | 2009-11-16 17:43:44 (GMT) |
---|---|---|
committer | Luis Ibanez <luis.ibanez@kitware.com> | 2009-11-16 17:43:44 (GMT) |
commit | 69fdf711fec78ccec28996fd0c0c807adcabf178 (patch) | |
tree | 8828b72b0afa6313c51f36a0fca6ab1b210d9c77 /Source | |
parent | 2921fa96ed836a49d2695b2787d9349885a30a9b (diff) | |
download | CMake-69fdf711fec78ccec28996fd0c0c807adcabf178.zip CMake-69fdf711fec78ccec28996fd0c0c807adcabf178.tar.gz CMake-69fdf711fec78ccec28996fd0c0c807adcabf178.tar.bz2 |
COMP: Fixing return type of the Get methods associated with variables that
were changed from "unsigned long" to "size_t" to solve warnings about
64 bits to 32 bits truncations.
Diffstat (limited to 'Source')
-rw-r--r-- | Source/kwsys/SystemInformation.cxx | 24 | ||||
-rw-r--r-- | Source/kwsys/SystemInformation.hxx.in | 8 |
2 files changed, 16 insertions, 16 deletions
diff --git a/Source/kwsys/SystemInformation.cxx b/Source/kwsys/SystemInformation.cxx index d460344..ecdedc7 100644 --- a/Source/kwsys/SystemInformation.cxx +++ b/Source/kwsys/SystemInformation.cxx @@ -128,10 +128,10 @@ public: bool DoesCPUSupportCPUID(); // Retrieve memory information in megabyte. - unsigned long GetTotalVirtualMemory(); - unsigned long GetAvailableVirtualMemory(); - unsigned long GetTotalPhysicalMemory(); - unsigned long GetAvailablePhysicalMemory(); + size_t GetTotalVirtualMemory(); + size_t GetAvailableVirtualMemory(); + size_t GetTotalPhysicalMemory(); + size_t GetAvailablePhysicalMemory(); /** Run the different checks */ void RunCPUCheck(); @@ -385,20 +385,20 @@ bool SystemInformation::DoesCPUSupportCPUID() } // Retrieve memory information in megabyte. -unsigned long SystemInformation::GetTotalVirtualMemory() +size_t SystemInformation::GetTotalVirtualMemory() { return this->Implementation->GetTotalVirtualMemory(); } -unsigned long SystemInformation::GetAvailableVirtualMemory() +size_t SystemInformation::GetAvailableVirtualMemory() { return this->Implementation->GetAvailableVirtualMemory(); } -unsigned long SystemInformation::GetTotalPhysicalMemory() +size_t SystemInformation::GetTotalPhysicalMemory() { return this->Implementation->GetTotalPhysicalMemory(); } -unsigned long SystemInformation::GetAvailablePhysicalMemory() +size_t SystemInformation::GetAvailablePhysicalMemory() { return this->Implementation->GetAvailablePhysicalMemory(); } @@ -2446,24 +2446,24 @@ int SystemInformationImplementation::QueryMemory() } /** */ -unsigned long SystemInformationImplementation::GetTotalVirtualMemory() +size_t SystemInformationImplementation::GetTotalVirtualMemory() { return this->TotalVirtualMemory; } /** */ -unsigned long SystemInformationImplementation::GetAvailableVirtualMemory() +size_t SystemInformationImplementation::GetAvailableVirtualMemory() { return this->AvailableVirtualMemory; } -unsigned long SystemInformationImplementation::GetTotalPhysicalMemory() +size_t SystemInformationImplementation::GetTotalPhysicalMemory() { return this->TotalPhysicalMemory; } /** */ -unsigned long SystemInformationImplementation::GetAvailablePhysicalMemory() +size_t SystemInformationImplementation::GetAvailablePhysicalMemory() { return this->AvailablePhysicalMemory; } diff --git a/Source/kwsys/SystemInformation.hxx.in b/Source/kwsys/SystemInformation.hxx.in index 9d073c4c..db23fe7 100644 --- a/Source/kwsys/SystemInformation.hxx.in +++ b/Source/kwsys/SystemInformation.hxx.in @@ -63,10 +63,10 @@ public: bool DoesCPUSupportCPUID(); // Retrieve memory information in megabyte. - unsigned long GetTotalVirtualMemory(); - unsigned long GetAvailableVirtualMemory(); - unsigned long GetTotalPhysicalMemory(); - unsigned long GetAvailablePhysicalMemory(); + size_t GetTotalVirtualMemory(); + size_t GetAvailableVirtualMemory(); + size_t GetTotalPhysicalMemory(); + size_t GetAvailablePhysicalMemory(); /** Run the different checks */ void RunCPUCheck(); |