* bcache.c (free_bcache): Do not free NULL.

This commit is contained in:
Andrew Cagney
2000-04-19 07:08:35 +00:00
parent 9debab2f37
commit df02e9ed85
2 changed files with 7 additions and 1 deletions

View File

@@ -189,7 +189,8 @@ void
free_bcache (struct bcache *bcache)
{
obstack_free (&bcache->cache, 0);
free (bcache->bucket);
if (bcache->bucket)
free (bcache->bucket);
/* This isn't necessary, but at least the bcache is always in a
consistent state. */