Skip to content

Commit 9162ed6

Browse files
lukasstraub2jasowang
authored andcommitted
net/colo-compare.c: Fix memory leak for non-tcp packet
Additional to removing the packet from the secondary queue, we also need to free it. Signed-off-by: Lukas Straub <lukasstraub2@web.de> Signed-off-by: Zhang Chen <chen.zhang@intel.com> Reviewed-by: Zhang Chen <chen.zhang@intel.com> Signed-off-by: Jason Wang <jasowang@redhat.com>
1 parent d4c6293 commit 9162ed6

File tree

1 file changed

+1
-0
lines changed

1 file changed

+1
-0
lines changed

net/colo-compare.c

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -690,6 +690,7 @@ static void colo_compare_packet(CompareState *s, Connection *conn,
690690

691691
if (result) {
692692
colo_release_primary_pkt(s, pkt);
693+
packet_destroy(result->data, NULL);
693694
g_queue_remove(&conn->secondary_list, result->data);
694695
} else {
695696
/*

0 commit comments

Comments
 (0)