Skip to content

Commit

Permalink
Fix memory leaks
Browse files Browse the repository at this point in the history
  • Loading branch information
Sober authored and lukebakken committed Mar 10, 2023
1 parent 4ed384c commit 1cb0070
Showing 1 changed file with 1 addition and 0 deletions.
1 change: 1 addition & 0 deletions consumers.go
Original file line number Diff line number Diff line change
Expand Up @@ -75,6 +75,7 @@ func (subs *consumers) buffer(in chan *Delivery, out chan Delivery) {
}

case out <- *queue[0]:
queue[0] = nil // Make the memory recycle normally
queue = queue[1:]
}
}
Expand Down

0 comments on commit 1cb0070

Please sign in to comment.