Fix wrong error handling 10/304310/1
authorHwankyu Jhun <h.jhun@samsung.com>
Tue, 16 Jan 2024 02:17:04 +0000 (11:17 +0900)
committerHwankyu Jhun <h.jhun@samsung.com>
Tue, 16 Jan 2024 02:17:04 +0000 (11:17 +0900)
If aul library does not find the client channel, the request must be ignored.

Change-Id: If45da924ad3479d1c02a51c7c48cbd68d689093d
Signed-off-by: Hwankyu Jhun <h.jhun@samsung.com>
src/aul_launch.c

index 6d1082c..da4bcd3 100644 (file)
@@ -402,8 +402,13 @@ static int __send_result(struct aul_request_s *req, int res)
 
        if (req->cmd != WIDGET_GET_CONTENT && req->clifd >= 0) {
                g_rec_mutex_lock(&__context.mutex);
-               if (__find_client_channel(req->clifd) == NULL)
-                       _E("Failed to find client channel. fd(%d)", req->clifd);
+               if (__find_client_channel(req->clifd) == NULL) {
+                       _E("Failed to find client channel. fd(%d), cmd(%s:%d)",
+                                       req->clifd,
+                                       aul_cmd_convert_to_string(req->cmd),
+                                       req->cmd);
+                       return -1;
+               }
 
                buf[0] = req->req_id;
                buf[1] = res;