summaryrefslogtreecommitdiff
path: root/plugins/openconnect.c
diff options
context:
space:
mode:
authorSamuel Ortiz <sameo@linux.intel.com>2010-07-30 16:02:44 +0200
committerSamuel Ortiz <sameo@linux.intel.com>2010-08-02 19:16:11 +0200
commitde41f828cf9decef412165c2895cb6ddc73be455 (patch)
treeb4d9723d41531e8f498bc1aac860cde59fb80b3a /plugins/openconnect.c
parent4fc2968ea3c3237bbb78bcd78391980b0727f06a (diff)
downloadconnman-de41f828cf9decef412165c2895cb6ddc73be455.tar.gz
connman-de41f828cf9decef412165c2895cb6ddc73be455.tar.bz2
connman-de41f828cf9decef412165c2895cb6ddc73be455.zip
Unref openconnect provider on disconnect and remove
Diffstat (limited to 'plugins/openconnect.c')
-rw-r--r--plugins/openconnect.c4
1 files changed, 4 insertions, 0 deletions
diff --git a/plugins/openconnect.c b/plugins/openconnect.c
index 891aa876..c860f27a 100644
--- a/plugins/openconnect.c
+++ b/plugins/openconnect.c
@@ -382,6 +382,8 @@ static int oc_disconnect(struct connman_provider *provider)
data->watch = 0;
connman_task_stop(data->task);
+ connman_provider_unref(provider);
+
return 0;
}
@@ -399,6 +401,8 @@ static int oc_remove(struct connman_provider *provider)
data->watch = 0;
connman_task_stop(data->task);
+ connman_provider_unref(provider);
+
g_usleep(G_USEC_PER_SEC);
kill_tun(data->if_name);
return 0;