More paranoid about freeing pointers.

This commit is contained in:
paul 1998-05-20 12:34:38 +00:00
parent 6e945d2b7b
commit 066ef682f3
1 changed files with 8 additions and 3 deletions

View File

@ -1,4 +1,4 @@
/* $Id: isdnconf.c,v 1.16 1998/05/19 15:55:57 paul Exp $
/* $Id: isdnconf.c,v 1.17 1998/05/20 12:34:38 paul Exp $
*
* ISDN accounting for isdn4linux. (Utilities)
*
@ -20,6 +20,9 @@
* Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA.
*
* $Log: isdnconf.c,v $
* Revision 1.17 1998/05/20 12:34:38 paul
* More paranoid about freeing pointers.
*
* Revision 1.16 1998/05/19 15:55:57 paul
* Moved config stuff for City Weekend from isdnlog.c to tools/isdnconf.c, so
* that isdnrep also understands a "cityweekend=y" line in isdn.conf.
@ -1054,8 +1057,10 @@ static int Set_Globals(section *SPtr)
{
while (sPtr != NULL)
{
free(sPtr[0]);
free(sPtr[1]);
if (sPtr[0])
free(sPtr[0]);
if (sPtr[1])
free(sPtr[1]);
free(sPtr);
sPtr++;