ecore_wl2_input: check return value of wl_display_dispatch() 71/310771/1 accepted/tizen/unified/20240509.011213 accepted/tizen/unified/toolchain/20240513.061336 accepted/tizen/unified/x/20240510.061436
authorJihoon Kim <jihoon48.kim@samsung.com>
Wed, 8 May 2024 04:27:02 +0000 (13:27 +0900)
committerJihoon Kim <jihoon48.kim@samsung.com>
Wed, 8 May 2024 04:27:02 +0000 (13:27 +0900)
Change-Id: I41e22e4f5a84d7ee2cec9db507f2c805cfdb7630
Signed-off-by: Jihoon Kim <jihoon48.kim@samsung.com>
src/lib/ecore_wl2/ecore_wl2_input.c

index 7db548c..5902b68 100644 (file)
@@ -2952,9 +2952,10 @@ static void
 _ecore_wl2_keygrab_result_wait(Ecore_Wl2_Display *ewd)
 {
    unsigned int wait_count = 0;
-   while ((_ecore_wl2_keygrab_error == -1) && (wait_count < MAX_WAIT_COUNT))
+   int ret = 0;
+   while ((ret >= 0) && (_ecore_wl2_keygrab_error == -1) && (wait_count < MAX_WAIT_COUNT))
      {
-        wl_display_dispatch(ewd->wl.display);
+        ret = wl_display_dispatch(ewd->wl.display);
         wait_count++;
      }
 }