Hi,
> Anyway, to the point. I tried my old MingW makefile on the latest git-repo.
> It stumbled on some code inside 'DEBUG_MALLOC'. Here in init.c (line 1737):
>
> for (i = 0; i < nurl; i++)
> xfree (url[i]);
>
> Should 'nurl' and 'url' in main.c be made public?
IMO, the cleanup() routine should go into main.c.
That is the right place - cleanup() is used only once at all (called by main()
in main.c).
Just to make it clear to other readers:
Right now, Wget fails to compile with -DDEBUG_MALLOC.
init.c: In function 'cleanup':
init.c:1737:8: error: 'i' undeclared (first use in this function)
for (i = 0; i < nurl; i++)
^
init.c:1737:8: note: each undeclared identifier is reported only once for each
function it appears in
init.c:1737:19: error: 'nurl' undeclared (first use in this function)
for (i = 0; i < nurl; i++)
^
init.c:1738:12: error: 'url' undeclared (first use in this function)
xfree (url[i]);
Thatnks for pointing this out.
Are you going to create a patch ?
Tim