summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorJaehyun Kim <jeik01.kim@samsung.com>2021-10-18 16:30:41 +0900
committerJaehyun Kim <jeik01.kim@samsung.com>2021-11-12 18:07:48 +0900
commit3ba19673cef612dadb33c1d6686c2df2e99e8f8c (patch)
tree88aa4540aa9f33e4da3a6ddd8051a9542e251555
parented5227c0fcf81c5ca07f0c884e86ff55d71c94a3 (diff)
downloadconnman-3ba19673cef612dadb33c1d6686c2df2e99e8f8c.tar.gz
connman-3ba19673cef612dadb33c1d6686c2df2e99e8f8c.tar.bz2
connman-3ba19673cef612dadb33c1d6686c2df2e99e8f8c.zip
Update settings when device information in device_list is changed
Modified to update enabled device information in settings when the powered value of each device in device_list is changed. Change-Id: I3ed4f236d747b9f979b23da19edbe1c248783f54 Signed-off-by: Jaehyun Kim <jeik01.kim@samsung.com>
-rwxr-xr-xsrc/device.c1
-rw-r--r--src/technology.c3
2 files changed, 4 insertions, 0 deletions
diff --git a/src/device.c b/src/device.c
index 53502821..377ef47e 100755
--- a/src/device.c
+++ b/src/device.c
@@ -740,6 +740,7 @@ int connman_device_set_powered(struct connman_device *device,
#if defined TIZEN_EXT
device_send_changed(device->interface, type, "Powered", powered);
+ technology_save_device(device);
#endif
if (!device->powered) {
diff --git a/src/technology.c b/src/technology.c
index 6a539dc0..4d48b12c 100644
--- a/src/technology.c
+++ b/src/technology.c
@@ -2223,6 +2223,9 @@ void technology_save_device(struct connman_device *device)
if (!technology)
return;
+ if (!g_slist_find(technology->device_list, device))
+ return;
+
GKeyFile *keyfile;
gchar *identifier;
const char *name = get_name(technology->type);