aboutsummaryrefslogtreecommitdiff
path: root/src
diff options
context:
space:
mode:
Diffstat (limited to 'src')
-rw-r--r--src/main.c5
1 files changed, 4 insertions, 1 deletions
diff --git a/src/main.c b/src/main.c
index 43155d5..7818f00 100644
--- a/src/main.c
+++ b/src/main.c
@@ -28,13 +28,14 @@ int main(int argc, char *argv[])
{
int i, numfps = 0;
bool ast = false;
- int files[argc];
+ int *files;
unsigned char buffer[4096];
cmark_doc_parser *parser;
size_t offset;
node_block *document;
parser = cmark_new_doc_parser();
+ files = (int *)malloc(argc * sizeof(*files));
for (i = 1; i < argc; i++) {
if (strcmp(argv[i], "--version") == 0) {
@@ -99,5 +100,7 @@ int main(int argc, char *argv[])
cmark_free_blocks(document);
end_timer("free_blocks");
+ free(files);
+
return 0;
}