From 16abff229fe782c6a8463a7e3b8df3f9c4a17283 Mon Sep 17 00:00:00 2001 From: Jukka Rissanen Date: Fri, 26 Apr 2013 15:51:33 +0300 Subject: [PATCH] technology: Disable tethering when device disappears If tethering is active when device is removed, then shutdown tethering cleanly so that tether interface and bridge are properly removed. --- src/technology.c | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/src/technology.c b/src/technology.c index f214367..10e6132 100644 --- a/src/technology.c +++ b/src/technology.c @@ -1367,6 +1367,10 @@ int __connman_technology_remove_device(struct connman_device *device) technology->device_list = g_slist_remove(technology->device_list, device); + + if (technology->tethering == TRUE) + set_tethering(technology, FALSE); + technology_put(technology); return 0; -- 2.7.4