Merge pull request #6 from christophe-duc/bugfix/fix_add_stats

fix a compile error
This commit is contained in:
Christophe 2026-01-07 20:32:01 -04:00 committed by GitHub
commit eabd38c75d
No known key found for this signature in database
GPG key ID: B5690EEEBB952194

View file

@ -412,9 +412,11 @@ func (r *LibpodRuntime) aggregatePodContainerStats(ctx context.Context, pod *lib
totalMemLimit += stats.MemLimit
totalPIDs += stats.PIDs
// Aggregate network stats
totalNetIn += stats.NetInput
totalNetOut += stats.NetOutput
// Aggregate network stats from all interfaces
for _, netStats := range stats.Network {
totalNetIn += netStats.RxBytes
totalNetOut += netStats.TxBytes
}
// Aggregate block I/O stats
totalBlockIn += stats.BlockInput