* libXg bug fix
@ 1998-09-15 23:03 Mark H. Wilkinson
0 siblings, 0 replies; only message in thread
From: Mark H. Wilkinson @ 1998-09-15 23:03 UTC (permalink / raw)
To: bobf; +Cc: sam-fans
This fixes a bug in ffree() in sam's libXg. c is a pointer to a
structure within an array of such structures, and as such shouldn't
be free'd. The later call to free(f->subf) frees the whole array.
I should point out that sam doesn't actually call ffree() anywhere,
so it's not going to fall over because of this. Other programs might.
-Mark.
Index: rdfontfile.c
===================================================================
RCS file: /u/cvs/9libs/libXg/rdfontfile.c,v
retrieving revision 1.4
retrieving revision 1.5
diff -C4 -r1.4 -r1.5
*** rdfontfile.c 1998/08/11 00:20:44 1.4
--- rdfontfile.c 1998/09/15 23:03:22 1.5
***************
*** 126,134 ****
c = f->subf+i;
if (c->f)
subffree(c->f);
free(c->name);
- free(c);
}
free(f->subf);
free(f);
}
--- 126,133 ----
^ permalink raw reply [flat|nested] only message in thread
only message in thread, other threads:[~1998-09-17 6:29 UTC | newest]
Thread overview: (only message) (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
1998-09-15 23:03 libXg bug fix Mark H. Wilkinson
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).