Skip to content

Commit 1a5cd0e

Browse files
committed
Review comments #1.
1 parent 544a917 commit 1a5cd0e

File tree

1 file changed

+1
-2
lines changed

1 file changed

+1
-2
lines changed

internal/profiling/buffer/buffer.go

Lines changed: 1 addition & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -257,8 +257,7 @@ func (cb *CircularBuffer) Drain() []interface{} {
257257

258258
result := make([]interface{}, 0)
259259
for i := 0; i < len(qs); i++ {
260-
acquired := atomic.LoadUint32(&qs[i].acquired)
261-
if acquired < qs[i].size {
260+
if acquired := atomic.LoadUint32(&qs[i].acquired); acquired < qs[i].size {
262261
result = dereferenceAppend(result, qs[i].arr, 0, acquired)
263262
} else {
264263
result = dereferenceAppend(result, qs[i].arr, 0, qs[i].size)

0 commit comments

Comments
 (0)