diff --git a/legacy/eina/src/include/eina_inlist.h b/legacy/eina/src/include/eina_inlist.h index 053582bb79..833d539a25 100644 --- a/legacy/eina/src/include/eina_inlist.h +++ b/legacy/eina/src/include/eina_inlist.h @@ -71,8 +71,8 @@ EAPI Eina_Accessor *eina_inlist_accessor_new(const Eina_Inlist *in_list) EINA_MA #define _EINA_INLIST_OFFSET(ref) ((char*)&(ref)->__in_list - (char*)(ref)) #define _EINA_INLIST_CONTAINER(ref, ptr) (void*)((char*)(ptr) - _EINA_INLIST_OFFSET(ref)) -#define EINA_INLIST_FOREACH(list, l) for (l = (list ? _EINA_INLIST_CONTAINER(l, list) : NULL); l; l = (EINA_INLIST_GET(l)->next ? _EINA_INLIST_CONTAINER(l, EINA_INLIST_GET(l)->next) : NULL)) -#define EINA_INLIST_REVERSE_FOREACH(list, l) for (l = (list ? _EINA_INLIST_CONTAINER(l, list->last) : NULL); l; l = (EINA_INLIST_GET(l)->prev ? _EINA_INLIST_CONTAINER(l, EINA_INLIST_GET(l)->prev) : NULL)) +#define EINA_INLIST_FOREACH(list, l) for (l = NULL, l = (list ? _EINA_INLIST_CONTAINER(l, list) : NULL); l; l = (EINA_INLIST_GET(l)->next ? _EINA_INLIST_CONTAINER(l, EINA_INLIST_GET(l)->next) : NULL)) +#define EINA_INLIST_REVERSE_FOREACH(list, l) for (l = NULL, l = (list ? _EINA_INLIST_CONTAINER(l, list->last) : NULL); l; l = (EINA_INLIST_GET(l)->prev ? _EINA_INLIST_CONTAINER(l, EINA_INLIST_GET(l)->prev) : NULL)) /**