aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--net/colo.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/net/colo.c b/net/colo.c
index 1f8162f..694f3c9 100644
--- a/net/colo.c
+++ b/net/colo.c
@@ -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));
}
}