summaryrefslogtreecommitdiff
path: root/src
diff options
context:
space:
mode:
authorJaehyun Kim <jeik01.kim@samsung.com>2024-09-09 21:04:18 +0900
committerJaehyun Kim <jeik01.kim@samsung.com>2024-09-09 21:04:44 +0900
commitf0df2ef000a365227bc82abbe051efba9886109a (patch)
treec65101398160159187e6862c9330035363a86456 /src
parent2ad72ed85e56b32031c09ab5993f1be33a9deac4 (diff)
downloadconnman-f0df2ef000a365227bc82abbe051efba9886109a.tar.gz
connman-f0df2ef000a365227bc82abbe051efba9886109a.tar.bz2
connman-f0df2ef000a365227bc82abbe051efba9886109a.zip
Fix NULL pointer dereference
Change-Id: Ib3f4732f7051d71179bff436feb9dffec08cb160 Signed-off-by: Jaehyun Kim <jeik01.kim@samsung.com>
Diffstat (limited to 'src')
-rwxr-xr-xsrc/device.c5
1 files changed, 5 insertions, 0 deletions
diff --git a/src/device.c b/src/device.c
index 580e325d..e07c6d2e 100755
--- a/src/device.c
+++ b/src/device.c
@@ -1183,6 +1183,11 @@ const char *connman_device_get_string(struct connman_device *device,
#endif
DBG("device %p key %s", device, key);
+#if defined TIZEN_EXT
+ if (!device)
+ return NULL;
+#endif
+
if (g_str_equal(key, "Address"))
return device->address;
else if (g_str_equal(key, "Name"))