ecore_con: allow for NULL to do nothing.

This commit is contained in:
Cedric Bail 2018-05-17 14:08:05 -07:00 committed by Cedric BAIL
parent 13ae5b1f0c
commit 301340baf6
1 changed files with 18 additions and 16 deletions

View File

@ -91,6 +91,7 @@ typedef struct _Ecore_Con_Lookup_Ctx {
#define ECORE_CON_SERVER_CHECK_RELAXED_RETURN(svr, ...) \
do \
{ \
if (!svr) return __VA_ARGS__; \
if (!ECORE_MAGIC_CHECK(svr, ECORE_MAGIC_CON_SERVER)) \
{ \
ECORE_MAGIC_FAIL(svr, ECORE_MAGIC_CON_SERVER, __FUNCTION__); \
@ -110,6 +111,7 @@ typedef struct _Ecore_Con_Lookup_Ctx {
#define ECORE_CON_CLIENT_CHECK_RELAXED_RETURN(cl, ...) \
do \
{ \
if (!cl) return __VA_ARGS__; \
if (!ECORE_MAGIC_CHECK(cl, ECORE_MAGIC_CON_CLIENT)) \
{ \
ECORE_MAGIC_FAIL(cl, ECORE_MAGIC_CON_CLIENT, __FUNCTION__); \