net/colo.c: No need to track conn_list for filter-rewriter
authorZhang Chen <chen.zhang@intel.com>
Fri, 1 Apr 2022 03:47:01 +0000 (11:47 +0800)
committerJason Wang <jasowang@redhat.com>
Wed, 20 Jul 2022 08:58:08 +0000 (16:58 +0800)
Filter-rewriter no need to track connection in conn_list.
This patch fix the glib g_queue_is_empty assertion when COLO guest
keep a lot of network connection.

Signed-off-by: Zhang Chen <chen.zhang@intel.com>
Reviewed-by: Li Zhijian <lizhijian@fujitsu.com>
Signed-off-by: Jason Wang <jasowang@redhat.com>
net/colo.c

index 1f8162f59f77c159f17958b76e4ab09bf8fe76f0..694f3c93ef82caa4b5b4373bfc64ad1a1ec8fe8d 100644 (file)
@@ -218,7 +218,7 @@ Connection *connection_get(GHashTable *connection_track_table,
             /*
              * clear the conn_list
              */
-            while (!g_queue_is_empty(conn_list)) {
+            while (conn_list && !g_queue_is_empty(conn_list)) {
                 connection_destroy(g_queue_pop_head(conn_list));
             }
         }