This is an automated email from the ASF dual-hosted git repository.
guangmingchen pushed a commit to branch master
in repository https://gitbox.apache.org/repos/asf/brpc.git
The following commit(s) were added to refs/heads/master by this push:
new d243ddf4 fix MPSCQueue memory not released with `DefaultAllocator`
(#2553)
d243ddf4 is described below
commit d243ddf4c1a8c35acd7c784537f5d3089077781f
Author: Lijin Xiong <[email protected]>
AuthorDate: Mon Mar 4 15:46:12 2024 +0800
fix MPSCQueue memory not released with `DefaultAllocator` (#2553)
Signed-off-by: Lijin Xiong <[email protected]>
Co-authored-by: Lijin Xiong <[email protected]>
---
src/butil/containers/mpsc_queue.h | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/src/butil/containers/mpsc_queue.h
b/src/butil/containers/mpsc_queue.h
index 4c7072da..45ab2ebe 100644
--- a/src/butil/containers/mpsc_queue.h
+++ b/src/butil/containers/mpsc_queue.h
@@ -145,7 +145,7 @@ bool MPSCQueue<T, Alloc>::DequeueImpl(T* data) {
ReverseList(node);
}
_cur_dequeue_node = node->next;
- return_object(old_node);
+ _alloc.Free(old_node);
return true;
}
---------------------------------------------------------------------
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]