diff --git a/binr/preload/Makefile b/binr/preload/Makefile index 104a7ba259..8255c66f8f 100644 --- a/binr/preload/Makefile +++ b/binr/preload/Makefile @@ -1,3 +1,6 @@ +ISPPC=$(shell uname -a | grep Power) + +ifeq ($(ISPPC),) BIN=libr2 ISLIB=1 BINDEPS=r_core r_parse r_search r_cons r_config @@ -22,3 +25,7 @@ include ../../shlr/ar/deps.mk clean:: rm -f $(BIN).$(EXT_SO) $(BIN).o +else +all: + @echo Cant build preloaded lib in old Macs +endif diff --git a/libr/util/rbtree.c b/libr/util/rbtree.c index 853e41344e..2ef2135be4 100644 --- a/libr/util/rbtree.c +++ b/libr/util/rbtree.c @@ -55,6 +55,7 @@ static inline RBIter bound_iter(RBNode *x, void *data, RBComparator cmp, bool up return it; } +/* static void _check1(RBNode *x, int dep, int black, bool leftmost) { static int black_; if (x) { @@ -74,6 +75,7 @@ static void _check1(RBNode *x, int dep, int black, bool leftmost) { static void _check(RBNode *x) { _check1 (x, 0, 0, true); } +*/ // Returns true if a node with an equal key is deleted R_API bool r_rbtree_aug_delete(RBNode **root, void *data, RBComparator cmp, RBNodeFree freefn, RBNodeSum sum) { diff --git a/libr/util/sys.c b/libr/util/sys.c index 86613641c9..15676e91ad 100644 --- a/libr/util/sys.c +++ b/libr/util/sys.c @@ -265,8 +265,9 @@ R_API int r_sys_clearenv(void) { return 0; } if (env) { - while (*environ) { - *environ++ = NULL; + char **e = env; + while (*e) { + *e++ = NULL; } } #else