summaryrefslogtreecommitdiff
path: root/src/technology.c
diff options
context:
space:
mode:
authorTomasz Bursztyka <tomasz.bursztyka@linux.intel.com>2012-10-26 10:33:11 +0300
committerPatrik Flykt <patrik.flykt@linux.intel.com>2012-10-26 10:53:38 +0300
commita859bcd92998cd539648e5589de1408e35837cb3 (patch)
treefe9ba08eb8d3496773b0e68adcafb2dd0d77fdb9 /src/technology.c
parent295cc8b57ce12257a9e90ea2e15e0d610e072e0a (diff)
downloadconnman-a859bcd92998cd539648e5589de1408e35837cb3.tar.gz
connman-a859bcd92998cd539648e5589de1408e35837cb3.tar.bz2
connman-a859bcd92998cd539648e5589de1408e35837cb3.zip
technology: Do not proceed with tethering if technology is not enabled
Fixes BMC#25846
Diffstat (limited to 'src/technology.c')
-rw-r--r--src/technology.c4
1 files changed, 4 insertions, 0 deletions
diff --git a/src/technology.c b/src/technology.c
index 324a1036..1ff8fb72 100644
--- a/src/technology.c
+++ b/src/technology.c
@@ -223,6 +223,10 @@ static int set_tethering(struct connman_technology *technology,
technology->driver->set_tethering == NULL)
return -EOPNOTSUPP;
+ __sync_synchronize();
+ if (technology->enabled == FALSE)
+ return -EACCES;
+
bridge = __connman_tethering_get_bridge();
if (bridge == NULL)
return -EOPNOTSUPP;