diff options
author | root <root> | 2010-03-09 09:00:59 +0000 |
---|---|---|
committer | root <root> | 2010-03-09 09:00:59 +0000 |
commit | 8d72baf42cefd50ba45ccac59064548635cdee1e (patch) | |
tree | 91bd3a249677ba0add295988bb7fd41d057aa9a5 | |
parent | f8a5a88f5cfab01064b05c5c8a0d5d0e63e24ec5 (diff) |
ev_avoid_stdio
-rw-r--r-- | ev.c | 4 |
1 files changed, 4 insertions, 0 deletions
@@ -570,6 +570,9 @@ ev_syserr (const char *msg) static void * ev_realloc_emul (void *ptr, long size) { +#if __GLIBC__ + return realloc (ptr, size); +#else /* some systems, notably openbsd and darwin, fail to properly * implement realloc (x, 0) (as required by both ansi c-98 and * the single unix specification, so work around them here. @@ -580,6 +583,7 @@ ev_realloc_emul (void *ptr, long size) free (ptr); return 0; +#endif } static void *(*alloc)(void *ptr, long size) = ev_realloc_emul; |