Fix integer sizing issues in the NetworkIO Meter

On Linux kernels the size of the values exported for network
device bytes and packets has used a 64 bit integer for quite
some time (2.6+ IIRC).  Make the procfs value extraction use
correct types and change internal types used to rate convert
these counters (within the NetworkIO Meter) 64 bit integers,
where appropriate.
This commit is contained in:
Nathan Scott
2021-03-01 11:55:15 +11:00
parent 379421d3b2
commit 2d1839289e
16 changed files with 85 additions and 133 deletions

View File

@ -233,15 +233,9 @@ bool Platform_getDiskIO(DiskIOData* data) {
return false;
}
bool Platform_getNetworkIO(unsigned long int* bytesReceived,
unsigned long int* packetsReceived,
unsigned long int* bytesTransmitted,
unsigned long int* packetsTransmitted) {
bool Platform_getNetworkIO(NetworkIOData* data) {
// TODO
*bytesReceived = 0;
*packetsReceived = 0;
*bytesTransmitted = 0;
*packetsTransmitted = 0;
(void)data;
return false;
}