evas textblock - fix inconsistent ascent/descent return ptr checks
authorCarsten Haitzler (Rasterman) <raster@rasterman.com>
Wed, 27 Aug 2014 08:37:01 +0000 (17:37 +0900)
committerCarsten Haitzler (Rasterman) <raster@rasterman.com>
Wed, 27 Aug 2014 08:37:01 +0000 (17:37 +0900)
ascent/descent are always non-null in usage of
_layout_item_ascent_descent_adjust() so don't check for them.

fix CID 1099704

src/lib/evas/canvas/evas_object_textblock.c

index b8f539bb3b413eee3ef851a98d4f2da04585a9f2..9cd26b14d5e54a0878247b3f8887c30ca951ca37 100644 (file)
@@ -2627,10 +2627,8 @@ _layout_item_ascent_descent_adjust(const Evas_Object *eo_obj,
           }
      }
 
-   if (ascent && (asc > *ascent))
-      *ascent = asc;
-   if (descent && (desc > *descent))
-      *descent = desc;
+   if (asc > *ascent) *ascent = asc;
+   if (desc > *descent) *descent = desc;
 
    if (fmt) _layout_format_ascent_descent_adjust(eo_obj, ascent, descent, fmt);
 }