优化代码

This commit is contained in:
刘祥超
2023-10-05 08:41:07 +08:00
parent d92f27c44b
commit d547793eee
2 changed files with 6 additions and 5 deletions

View File

@@ -41,7 +41,7 @@ func StartMemoryStats(t *testing.T) {
for range ticker.C {
runtime.ReadMemStats(stat)
if stat.HeapInuse == lastHeapInUse {
return
continue
}
lastHeapInUse = stat.HeapInuse