diff options
author | Alan Modra <amodra@gmail.com> | 2005-10-26 12:17:42 +0000 |
---|---|---|
committer | Alan Modra <amodra@gmail.com> | 2005-10-26 12:17:42 +0000 |
commit | 3dff57e8474430c098331cde4b2601944f00ae6f (patch) | |
tree | cfa1a155c8d2e748bf459ec121c0deced61d7092 /bfd/trad-core.c | |
parent | 89feb2c4127287b6e3dc829bc0d4daf8ca857f20 (diff) | |
download | binutils-gdb-3dff57e8474430c098331cde4b2601944f00ae6f.tar.gz |
* cache.c (bfd_cache_lookup_worker): Don't abort on failing to
reopen file.
(cache_btell, cache_bseek, cache_bflush, cache_bstat): Return -1 on
bfd_cache_lookup failure.
(cache_bread, cache_bwrite): Return 0 on the same.
* bfdwin.c (bfd_get_file_window): Likewise.
* hppabsd-core.c (hppabsd_core_core_file_p): Likewise.
* sco5-core.c (sco5_core_file_p): Likewise.
* trad-core.c (trad_unix_core_file_p): Likewise.
Diffstat (limited to 'bfd/trad-core.c')
-rw-r--r-- | bfd/trad-core.c | 2 |
1 files changed, 2 insertions, 0 deletions
diff --git a/bfd/trad-core.c b/bfd/trad-core.c index defad69f467..c958683344a 100644 --- a/bfd/trad-core.c +++ b/bfd/trad-core.c @@ -112,6 +112,8 @@ trad_unix_core_file_p (abfd) FILE *stream = bfd_cache_lookup (abfd); struct stat statbuf; + if (stream == NULL) + return 0; if (fstat (fileno (stream), &statbuf) < 0) { bfd_set_error (bfd_error_system_call); |