summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorLubomir Rintel <lkundrak@v3.sk>2015-02-18 16:13:57 +0100
committerLubomir Rintel <lkundrak@v3.sk>2015-02-18 18:10:47 +0100
commite5499c558f47733c2753c202a7010ae2ab4c1a6f (patch)
treeae3d36e0e2469573f1542bba24b39e68b6c06417
parentf93f0e0b15830e4e265ad7b6877407e64f0185f2 (diff)
downloadNetworkManager-e5499c558f47733c2753c202a7010ae2ab4c1a6f.tar.gz
connectivity: memleak: drop async result reference on complete
==5177== 104 (+104) bytes in 1 (+1) blocks are definitely lost in loss record 5,502 of 6,581 ==5177== at 0x4C29BCF: malloc (in /usr/lib64/valgrind/vgpreload_memcheck-amd64-linux.so) ==5177== by 0x7F4A6F5: g_malloc (gmem.c:97) ==5177== by 0x7F6159F: g_slice_alloc (gslice.c:1007) ==5177== by 0x7F61B6D: g_slice_alloc0 (gslice.c:1032) ==5177== by 0x7CDB9A3: g_type_create_instance (gtype.c:1847) ==5177== by 0x7CBF356: g_object_new_internal (gobject.c:1774) ==5177== by 0x7CC0D4C: g_object_newv (gobject.c:1922) ==5177== by 0x7CC14E3: g_object_new (gobject.c:1614) ==5177== by 0x79A4C57: g_simple_async_result_new (gsimpleasyncresult.c:319) ==5177== by 0x515B34: nm_connectivity_check_async (nm-connectivity.c:289) ==5177== by 0x515D74: run_check (nm-connectivity.c:217) ==5177== by 0x515DBF: idle_start_periodic_checks (nm-connectivity.c:229)
-rw-r--r--src/nm-connectivity.c2
1 files changed, 2 insertions, 0 deletions
diff --git a/src/nm-connectivity.c b/src/nm-connectivity.c
index 804e3935fe..34465aad03 100644
--- a/src/nm-connectivity.c
+++ b/src/nm-connectivity.c
@@ -186,6 +186,7 @@ nm_connectivity_check_cb (SoupSession *session, SoupMessage *msg, gpointer user_
g_simple_async_result_set_op_res_gssize (simple, new_state);
g_simple_async_result_complete (simple);
+ g_object_unref (simple);
g_free (cb_data->uri);
g_free (cb_data->response);
@@ -321,6 +322,7 @@ nm_connectivity_check_async (NMConnectivity *self,
g_simple_async_result_set_op_res_gssize (simple, priv->state);
g_simple_async_result_complete_in_idle (simple);
+ g_object_unref (simple);
}
NMConnectivityState