mirror of
https://github.com/xzeldon/htop.git
synced 2025-07-12 12:14:36 +03:00
Hold only a const version of the ProcessList in Meters
This commit is contained in:

committed by
cgzones

parent
f757810f48
commit
72103e9613
@ -18,7 +18,7 @@ static const int ZfsArcMeter_attributes[] = {
|
||||
ZFS_MFU, ZFS_MRU, ZFS_ANON, ZFS_HEADER, ZFS_OTHER
|
||||
};
|
||||
|
||||
void ZfsArcMeter_readStats(Meter* this, ZfsArcStats* stats) {
|
||||
void ZfsArcMeter_readStats(Meter* this, const ZfsArcStats* stats) {
|
||||
this->total = stats->max;
|
||||
this->values[0] = stats->MFU;
|
||||
this->values[1] = stats->MRU;
|
||||
|
@ -11,7 +11,7 @@ in the source distribution for its full text.
|
||||
|
||||
#include "Meter.h"
|
||||
|
||||
void ZfsArcMeter_readStats(Meter* this, ZfsArcStats* stats);
|
||||
void ZfsArcMeter_readStats(Meter* this, const ZfsArcStats* stats);
|
||||
|
||||
extern const MeterClass ZfsArcMeter_class;
|
||||
|
||||
|
@ -21,7 +21,7 @@ static const int ZfsCompressedArcMeter_attributes[] = {
|
||||
ZFS_COMPRESSED
|
||||
};
|
||||
|
||||
void ZfsCompressedArcMeter_readStats(Meter* this, ZfsArcStats* stats) {
|
||||
void ZfsCompressedArcMeter_readStats(Meter* this, const ZfsArcStats* stats) {
|
||||
if ( stats->isCompressed ) {
|
||||
this->total = stats->uncompressed;
|
||||
this->values[0] = stats->compressed;
|
||||
|
@ -11,7 +11,7 @@ in the source distribution for its full text.
|
||||
|
||||
#include "Meter.h"
|
||||
|
||||
void ZfsCompressedArcMeter_readStats(Meter* this, ZfsArcStats* stats);
|
||||
void ZfsCompressedArcMeter_readStats(Meter* this, const ZfsArcStats* stats);
|
||||
|
||||
extern const MeterClass ZfsCompressedArcMeter_class;
|
||||
|
||||
|
Reference in New Issue
Block a user