This is the mail archive of the
gcc-patches@gcc.gnu.org
mailing list for the GCC project.
Fix PR 7711
- From: Nathan Sidwell <nathan at codesourcery dot com>
- To: gcc-patches at gcc dot gnu dot org
- Date: Fri, 13 Sep 2002 22:52:08 +0100
- Subject: Fix PR 7711
- Organization: Codesourcery LLC
Hi,
I've installed this obvious fix for 7711 - sometimes a hash table isn't
initialized.
nathan
--
Dr Nathan Sidwell :: http://www.codesourcery.com :: CodeSourcery LLC
'But that's a lie.' - 'Yes it is. What's your point?'
nathan@codesourcery.com : http://www.cs.bris.ac.uk/~nathan/ : nathan@acm.org
2002-09-13 Nathan Sidwell <nathan@codesourcery.com>
* ggc-common.c (ggc_mark_roots): Don't iterate NULL hash tables.
Index: ggc-common.c
===================================================================
RCS file: /cvs/gcc/gcc/gcc/ggc-common.c,v
retrieving revision 1.54
diff -c -3 -p -r1.54 ggc-common.c
*** ggc-common.c 4 Jun 2002 17:32:52 -0000 1.54
--- ggc-common.c 13 Sep 2002 21:38:38 -0000
*************** ggc_mark_roots ()
*** 128,134 ****
they are not already marked. */
for (ct = gt_ggc_cache_rtab; *ct; ct++)
for (cti = *ct; cti->base != NULL; cti++)
! htab_traverse (*cti->base, ggc_htab_delete, (PTR) cti);
}
/* R had not been previously marked, but has now been marked via
--- 128,135 ----
they are not already marked. */
for (ct = gt_ggc_cache_rtab; *ct; ct++)
for (cti = *ct; cti->base != NULL; cti++)
! if (*cti->base)
! htab_traverse (*cti->base, ggc_htab_delete, (PTR) cti);
}
/* R had not been previously marked, but has now been marked via