diff --git a/bfd/ChangeLog b/bfd/ChangeLog index 8ab0844e40..904f0b8e82 100644 --- a/bfd/ChangeLog +++ b/bfd/ChangeLog @@ -1,3 +1,7 @@ +2004-04-22 Andrew Cagney + + * cache.c (bfd_cache_close): Check for a previously closed file. + 2004-04-22 Jakub Jelinek * bfd.c (bfd_get_synthetic_symtab): Define. diff --git a/bfd/cache.c b/bfd/cache.c index 9146c05cac..0586061286 100644 --- a/bfd/cache.c +++ b/bfd/cache.c @@ -336,6 +336,10 @@ bfd_cache_close (bfd *abfd) if (abfd->iovec != &cache_iovec) return TRUE; + if (abfd->iostream == NULL) + /* Previously closed. */ + return TRUE; + return bfd_cache_delete (abfd); }