uxn

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

commit 04e4edf05f0a915e40cdf4a9f76b0a57041ee7e3
parent 99e38d560ce5b4cab3cc54628c02b9919095e965
Author: neauoire <aliceffekt@gmail.com>
Date:   Sun, 17 Oct 2021 19:10:29 -0700

Fixed an issue with the ref counter in uxnasm

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

diff --git a/src/uxnasm.c b/src/uxnasm.c @@ -191,9 +191,10 @@ addref(Label *l, Uint8 rel) if(rel) { int pos = cpos(l->name, '/'); if(pos != -1) { - char root[64]; - Label *rl = findlabel(scpy(l->name, root, pos)); - ++rl->refs; + char parent[64]; + Label *rl = findlabel(scpy(l->name, parent, pos)); + if(rl) + ++rl->refs; } } return ++l->refs;