scc

simple c99 compiler
git clone git://git.simple-cc.org/scc
Log | Files | Refs | Submodules | README | LICENSE

commit f0ab36a28cabf0dc9d5eac36007eae2614b4e91f
parent a4c16d5f8e4ca22c7aebb3ff2f3de953325bf42c
Author: Roberto E. Vargas Caballero <k0ga@shike2.com>
Date:   Fri, 17 Jan 2025 23:30:30 +0100

size: Initialize membname for each file

When we process a new file we have to clean membname because
we don't know if we are processing an object or a library,
and what we do know if that we don't want to carry values
from the previous file.

Diffstat:
Msrc/cmd/scc-size.c | 1+
1 file changed, 1 insertion(+), 0 deletions(-)

diff --git a/src/cmd/scc-size.c b/src/cmd/scc-size.c @@ -132,6 +132,7 @@ size(char *fname) int t; FILE *fp; + membname = NULL; filename = fname; if ((fp = fopen(fname, "rb")) == NULL) { error(strerror(errno));