projects
/
framework
/
connectivity
/
connman.git
/ commitdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
| commitdiff |
tree
raw
|
patch
|
inline
| side by side (parent:
0203ef7
)
device: Set scan interval to 0 if background scaniing is disabled
author
Samuel Ortiz
<sameo@linux.intel.com>
Fri, 1 Apr 2011 23:42:45 +0000
(
01:42
+0200)
committer
Samuel Ortiz
<sameo@linux.intel.com>
Fri, 1 Apr 2011 23:42:45 +0000
(
01:42
+0200)
src/device.c
patch
|
blob
|
history
diff --git
a/src/device.c
b/src/device.c
index
bc757c9
..
72b8656
100644
(file)
--- a/
src/device.c
+++ b/
src/device.c
@@
-462,6
+462,7
@@
struct connman_device *connman_device_create(const char *node,
struct connman_device *device;
const char *str;
enum connman_service_type service_type;
struct connman_device *device;
const char *str;
enum connman_service_type service_type;
+ connman_bool_t bg_scan;
DBG("node %s type %d", node, type);
DBG("node %s type %d", node, type);
@@
-471,6
+472,8
@@
struct connman_device *connman_device_create(const char *node,
DBG("device %p", device);
DBG("device %p", device);
+ bg_scan = connman_configuration_get_bool("BackgroundScanning");
+
__connman_element_initialize(&device->element);
device->element.name = g_strdup(node);
__connman_element_initialize(&device->element);
device->element.name = g_strdup(node);
@@
-509,7
+512,10
@@
struct connman_device *connman_device_create(const char *node,
device->scan_interval = 0;
break;
case CONNMAN_DEVICE_TYPE_WIFI:
device->scan_interval = 0;
break;
case CONNMAN_DEVICE_TYPE_WIFI:
- device->scan_interval = 300;
+ if (bg_scan == TRUE)
+ device->scan_interval = 300;
+ else
+ device->scan_interval = 0;
break;
}
break;
}