From c97aa87faf09b6ee35f7f6228c3a3976f5c0335c Mon Sep 17 00:00:00 2001 From: neauoire Date: Sat, 10 Dec 2022 11:07:45 -0800 Subject: [PATCH] (uxnasm)Allow more space for symbols filename, and check for length --- src/uxnasm.c | 7 +++++-- 1 file changed, 5 insertions(+), 2 deletions(-) diff --git a/src/uxnasm.c b/src/uxnasm.c index 454eb9d..40e280f 100644 --- a/src/uxnasm.c +++ b/src/uxnasm.c @@ -451,8 +451,11 @@ review(char *filename) static void writesym(char *filename) { - char symdst[0x40]; - FILE *fp = fopen(scat(scpy(filename, symdst, slen(filename) + 1), ".sym"), "w"); + char symdst[0x60]; + FILE *fp + if(slen(filename) > 0x60 - 5) + return; + fp = fopen(scat(scpy(filename, symdst, slen(filename) + 1), ".sym"), "w"); int i; if(fp != NULL) { for(i = 0; i < p.llen; i++) {