summaryrefslogtreecommitdiff
path: root/src/device.c
diff options
context:
space:
mode:
authorNiraj Kumar Goit <niraj.g@samsung.com>2017-09-04 17:31:38 +0530
committerNiraj Kumar Goit <niraj.g@samsung.com>2017-09-07 09:34:35 +0530
commit4aa5c133cfdb1cd96fc3b661ba15ffff7c2b90ec (patch)
tree667ea34008e74b7c8fb7eabd2c2f6f62e9d9979e /src/device.c
parentc98b80f557bad82b6f9f671fc7a8505e3137fb5e (diff)
downloadconnman-4aa5c133cfdb1cd96fc3b661ba15ffff7c2b90ec.tar.gz
connman-4aa5c133cfdb1cd96fc3b661ba15ffff7c2b90ec.tar.bz2
connman-4aa5c133cfdb1cd96fc3b661ba15ffff7c2b90ec.zip
[connman] Notify 'ScanDone' signal with scan-type info.
Description: In this patch added below changes- 1. Notify ScanDone signal with scan-type info. 2. If scanning is in-progress at connman return error 'InProgress' to application. Change-Id: If8427e185dd0ad811c1d1de72254f073babebbbf Signed-off-by: Niraj Kumar Goit <niraj.g@samsung.com>
Diffstat (limited to 'src/device.c')
-rwxr-xr-xsrc/device.c10
1 files changed, 9 insertions, 1 deletions
diff --git a/src/device.c b/src/device.c
index acd68da4..b5855cc2 100755
--- a/src/device.c
+++ b/src/device.c
@@ -1129,7 +1129,7 @@ int __connman_device_request_specific_scan(enum connman_service_type type,
}
err = device_specific_scan(type, device, scan_type, specific_scan_list);
- if (err == 0 || err == -EALREADY || err == -EINPROGRESS) {
+ if (err == 0 || err == -EINPROGRESS) {
success = true;
} else {
last_err = err;
@@ -1180,7 +1180,15 @@ int __connman_device_request_scan(enum connman_service_type type)
}
err = device_scan(type, device);
+#if defined TIZEN_EXT
+ /* When Scan is already in progress then return Error so that
+ * wifi-manager can block the scan-done signal to be sent to
+ * application and start requested scan after scan already in progress
+ * is completed then notify to application about the scan event */
+ if (err == 0 || err == -EINPROGRESS) {
+#else
if (err == 0 || err == -EALREADY || err == -EINPROGRESS) {
+#endif
success = true;
} else {
last_err = err;