[RFA] bfd_cache_close_all
Alan Modra
amodra@bigpond.net.au
Thu Jun 17 02:22:00 GMT 2004
On Wed, Jun 16, 2004 at 07:17:48PM +0200, Jerome Guitton wrote:
> The idea would be to have a function bfd_cache_close_all that would
> clear the file descriptor cache.
>
> OK to apply?
> + if (!bfd_last_cache)
> + return TRUE;
> +
> + for (kill = bfd_last_cache->lru_prev;
> + open_files;
> + kill = kill->lru_prev)
> + {
> + ret = ret && bfd_cache_close (kill);
> + }
No need to close oldest first. OK with the following change to simplify
the code.
while (bfd_last_cache != NULL)
ret &= bfd_cache_close (bfd_last_cache);
--
Alan Modra
IBM OzLabs - Linux Technology Centre
More information about the Gdb-patches
mailing list