On 2017年02月16日 10:25, Zhang Chen wrote:
@@ -703,13 +704,11 @@ static void colo_compare_finalize(Object *obj)
      qemu_chr_fe_deinit(&s->chr_sec_in);
      qemu_chr_fe_deinit(&s->chr_out);
  -    g_queue_free(&s->conn_list);
+    g_main_loop_quit(s->compare_loop);
+    qemu_thread_join(&s->thread);
  -    if (qemu_thread_is_self(&s->thread)) {
-        /* compare connection */
-        g_queue_foreach(&s->conn_list, colo_compare_connection, s);
-        qemu_thread_join(&s->thread);
-    }

Before free the 's->conn_list', you should flush all queued primary packets and release all queued secondary packets here, so combine this patch with 3/5 patch as
one patch is a better choose.

Thanks
Zhang Chen

Yes, agree.

Thanks

Reply via email to