* cache.c (bfd_cache_lookup_worker): Use bfd_error_handler
authorAlan Modra <amodra@gmail.com>
Wed, 26 Oct 2005 07:38:25 +0000 (07:38 +0000)
committerAlan Modra <amodra@gmail.com>
Wed, 26 Oct 2005 07:38:25 +0000 (07:38 +0000)
rather than bfd_perror.  Print file name.  Internationalise.

bfd/ChangeLog
bfd/cache.c

index a1e35e0b1d2975bb98eb1f0ed7ba6b5a41981cd3..01987b1d05cd608d7b901eb64b6a30f1054b89e2 100644 (file)
@@ -1,3 +1,8 @@
+2005-10-26  Alan Modra  <amodra@bigpond.net.au>
+
+       * cache.c (bfd_cache_lookup_worker): Use bfd_error_handler
+       rather than bfd_perror.  Print file name.  Internationalise.
+
 2005-10-26  Alan Modra  <amodra@bigpond.net.au>
 
        * cache.c (bfd_open_file): Set bfd_error_system_call on failure
index e9f38ab6b40a415a6e77d1d52bb4b713bc556f12..88d0c984552333300f93f915047e4c0dbde93f0c 100644 (file)
@@ -477,6 +477,7 @@ DESCRIPTION
 FILE *
 bfd_cache_lookup_worker (bfd *abfd)
 {
+  bfd *orig_bfd = abfd;
   if ((abfd->flags & BFD_IN_MEMORY) != 0)
     abort ();
 
@@ -501,7 +502,8 @@ bfd_cache_lookup_worker (bfd *abfd)
   else
     return (FILE *) abfd->iostream;
 
-  bfd_perror ("Cannot continue");
+  (*_bfd_error_handler) (_("reopening %B: %s\n"),
+                        orig_bfd, bfd_errmsg (bfd_get_error ()));
   abort ();
   return NULL;
 }
This page took 0.042335 seconds and 4 git commands to generate.