uxn

Varvara Ordinator, written in ANSI C(SDL2)
git clone https://git.eamoncaddigan.net/uxn.git
Log | Files | Refs | README | LICENSE

commit c97aa87faf09b6ee35f7f6228c3a3976f5c0335c
parent 2f3954d398009a77340890edc83f8997cc41485b
Author: neauoire <aliceffekt@gmail.com>
Date:   Sat, 10 Dec 2022 11:07:45 -0800

(uxnasm)Allow more space for symbols filename, and check for length

Diffstat:
Msrc/uxnasm.c | 7+++++--
1 file changed, 5 insertions(+), 2 deletions(-)

diff --git 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++) {