From: rohit singh Date: Wed, 9 Jun 2021 10:38:47 +0000 (+0530) Subject: Fix derefencing of null pointer issue X-Git-Tag: accepted/tizen/unified/20210615.120246^0 X-Git-Url: http://review.tizen.org/git/?a=commitdiff_plain;h=a21c3e2d971385ab2d9fe811bf7fd88df6f9f40d;p=platform%2Fcore%2Fconnectivity%2Fua-manager.git Fix derefencing of null pointer issue Return value of a function '__search_device' is dereferenced inside __init_svc_user_mapping() function. Change-Id: Ibeb9cdc49dc5fdfa8c94f036dca5c6802c0929eb Signed-off-by: rohit.singh --- diff --git a/ua-daemon/src/ua-manager-core.c b/ua-daemon/src/ua-manager-core.c index 7a58c30..6195c78 100755 --- a/ua-daemon/src/ua-manager-core.c +++ b/ua-daemon/src/ua-manager-core.c @@ -1024,6 +1024,8 @@ static void __init_svc_user_mapping() /* Search for devices */ ll = __search_device(device_id, svc_dev->app_num); + if (NULL == ll) + continue; uam_db_device_info_t *device = ll->data; uam_db_user_info_t *user_info = device->user;