Merge pull request #2776 from cremno/undef-strndup

prevent accidental macro redefinition of strndup()
This commit is contained in:
Yukihiro "Matz" Matsumoto
2015-04-30 12:17:14 +09:00
+1
View File
@@ -201,6 +201,7 @@ parser_strndup(parser_state *p, const char *s, size_t len)
b[len] = '\0';
return b;
}
#undef strndup
#define strndup(s,len) parser_strndup(p, s, len)
static char*