fix svace issue 93/307293/1 accepted/tizen_unified accepted/tizen_unified_x tizen accepted/tizen/unified/20240307.171905 accepted/tizen/unified/x/20240311.095909
authorduna.oh <duna.oh@samsung.com>
Thu, 7 Mar 2024 02:06:57 +0000 (11:06 +0900)
committerduna.oh <duna.oh@samsung.com>
Thu, 7 Mar 2024 02:06:57 +0000 (11:06 +0900)
Change-Id: I1594d2c11e3477558969b58891e86384a24f3d1c

src/e_mod_gesture_events.c

index 4656be8..3c6ee48 100644 (file)
@@ -156,8 +156,11 @@ _e_gesture_util_center_axis_get(int num_finger, int *x, int *y)
         cnt++;
      }
 
-   calc_x = (int)(calc_x / cnt);
-   calc_y = (int)(calc_y / cnt);
+   if (cnt > 1)
+     {
+        calc_x = (int)(calc_x / cnt);
+        calc_y = (int)(calc_y / cnt);
+     }
 
    *x = calc_x;
    *y = calc_y;