diff options
Diffstat (limited to 'test/parser.c')
-rw-r--r-- | test/parser.c | 4 |
1 files changed, 3 insertions, 1 deletions
diff --git a/test/parser.c b/test/parser.c index 41dd41b..0670ebf 100644 --- a/test/parser.c +++ b/test/parser.c @@ -25,7 +25,7 @@ static int run_test(int argc, char **argv, unsigned int CHUNK_SIZE) hubbub_parser_optparams params; FILE *fp; size_t len, origlen; - uint8_t *buf = alloca(CHUNK_SIZE); + uint8_t *buf = malloc(CHUNK_SIZE); const char *charset; hubbub_charset_source cssource; @@ -65,6 +65,8 @@ static int run_test(int argc, char **argv, unsigned int CHUNK_SIZE) fclose(fp); + free(buf); + charset = hubbub_parser_read_charset(parser, &cssource); printf("Charset: %s (from %d)\n", charset, cssource); |