ecore_wl2: add null check for pointer when requesting lock_pointer 73/303473/1 accepted/tizen/unified/20240101.155343 accepted/tizen/unified/riscv/20240103.054635
authorduna.oh <duna.oh@samsung.com>
Thu, 28 Dec 2023 06:54:44 +0000 (15:54 +0900)
committerduna.oh <duna.oh@samsung.com>
Thu, 28 Dec 2023 07:01:15 +0000 (16:01 +0900)
Change-Id: I3bd4816e5fef18777debe44dd581210bde6b72f0

src/lib/ecore_wl2/ecore_wl2_input.c

index 09bfd29..c7399dc 100644 (file)
@@ -4190,6 +4190,11 @@ ecore_wl2_window_pointer_constraints_lock_pointer(Ecore_Wl2_Window *win)
    input = ecore_wl2_input_default_input_get(ewd);
    EINA_SAFETY_ON_NULL_RETURN_VAL(input, EINA_FALSE);
 
+   if (!input->wl.pointer)
+     {
+        ERR("Failed to lock pointer. pointer is NULL");
+        return EINA_FALSE;
+     }
    if (!ewd->wl.pointer_constraints)
      {
         ERR("Failed to lock pointer. constraints is NULL");