aboutsummaryrefslogtreecommitdiffstats
path: root/tools/syz-testbed/stats.go
diff options
context:
space:
mode:
authorDmitry Vyukov <dvyukov@google.com>2025-01-17 10:28:16 +0100
committerDmitry Vyukov <dvyukov@google.com>2025-01-17 10:02:07 +0000
commit5d04aae8969f6c72318ce0a4cde4f027766b1a55 (patch)
tree8f1b632847c431407090f0fe1335522ff2195a37 /tools/syz-testbed/stats.go
parentf9e07a6e597b68d3397864e6ee4550f9065c3518 (diff)
all: use min/max functions
They are shorter, more readable, and don't require temp vars.
Diffstat (limited to 'tools/syz-testbed/stats.go')
-rw-r--r--tools/syz-testbed/stats.go5
1 files changed, 1 insertions, 4 deletions
diff --git a/tools/syz-testbed/stats.go b/tools/syz-testbed/stats.go
index 6044bfe3d..9f338f4bb 100644
--- a/tools/syz-testbed/stats.go
+++ b/tools/syz-testbed/stats.go
@@ -217,10 +217,7 @@ func (group RunResultGroup) minResultLength() int {
results := group.SyzManagerResults()
ret := len(results[0].StatRecords)
for _, result := range results {
- currLen := len(result.StatRecords)
- if currLen < ret {
- ret = currLen
- }
+ ret = min(ret, len(result.StatRecords))
}
return ret
}