Undefs strdup before overriding it in alloc.h

master
itamar 8 years ago
parent 2a9b54f7b9
commit 4c62df8a4e

@ -27,10 +27,14 @@ char *rmalloc_strndup(const char *s, size_t n);
#define calloc(count, size) RedisModule_Calloc(count, size)
#define realloc(ptr, size) RedisModule_Realloc(ptr, size)
#define free(ptr) RedisModule_Free(ptr)
#ifdef strdup
#undef strdup
#endif
#define strdup(ptr) RedisModule_Strdup(ptr)
// /* More overriding */
// // needed to avoid calling strndup->malloc
/* More overriding */
// needed to avoid calling strndup->malloc
#ifdef strndup
#undef strndup
#endif

Loading…
Cancel
Save