From: Jérémy Zurcher Date: Thu, 26 Dec 2013 15:16:55 +0000 (+0100) Subject: eo2: do not call eo2_do_end() if eo2_do_start() fail X-Git-Tag: v1.10.0-alpha1~200^2~128 X-Git-Url: http://review.tizen.org/git/?a=commitdiff_plain;h=329d752c594cd8124ef84bae6f12928202217f46;p=platform%2Fupstream%2Fefl.git eo2: do not call eo2_do_end() if eo2_do_start() fail --- diff --git a/src/lib/eo/Eo.h b/src/lib/eo/Eo.h index 49b5179..da420c7 100644 --- a/src/lib/eo/Eo.h +++ b/src/lib/eo/Eo.h @@ -685,21 +685,22 @@ EAPI int eo2_call_stack_depth(); #define EO2_DO_CLEANUP __attribute__((cleanup(eo2_do_end))) // eo object method calls batch, -// DO NOT use return statement in it, use break if necessary #define eo2_do(objid, ...) \ do \ { \ + if (!eo2_do_start(objid, EINA_FALSE)) break; \ Eo *_objid_ EO2_DO_CLEANUP = objid; \ - if (!eo2_do_start(_objid_, EINA_FALSE)) break; \ __VA_ARGS__; \ + (void) _objid_; \ } while (0) #define eo2_do_super(objid, ...) \ do \ { \ + if (!eo2_do_start(objid, EINA_TRUE)) break; \ Eo *_objid_ EO2_DO_CLEANUP = objid; \ - if (!eo2_do_start(_objid_, EINA_TRUE)) break; \ __VA_ARGS__; \ + (void) _objid_; \ } while (0) // FIXME