gdb: add target_ops::supports_displaced_step
[deliverable/binutils-gdb.git] / bfd / osf-core.c
index ed5fbbe159829216d7ea89c6da36e0c411ef3270..3f384e7bd404a734fa3899a8970bd88488fdc2a3 100644 (file)
@@ -1,6 +1,5 @@
 /* BFD back-end for OSF/1 core files.
-   Copyright 1993, 1994, 1995, 1998, 1999, 2001, 2002, 2003, 2004, 2005, 2006,
-   2007, 2010, 2011, 2012 Free Software Foundation, Inc.
+   Copyright (C) 1993-2020 Free Software Foundation, Inc.
 
    This file is part of BFD, the Binary File Descriptor library.
 
@@ -71,14 +70,14 @@ make_bfd_asection (bfd *abfd,
   return asect;
 }
 
-static const bfd_target *
+static bfd_cleanup
 osf_core_core_file_p (bfd *abfd)
 {
   int val;
   int i;
   char *secname;
   struct core_filehdr core_header;
-  bfd_size_type amt;
+  size_t amt;
 
   amt = sizeof core_header;
   val = bfd_bread (& core_header, amt, abfd);
@@ -125,8 +124,8 @@ osf_core_core_file_p (bfd *abfd)
          flags = SEC_HAS_CONTENTS;
          break;
        default:
-         (*_bfd_error_handler) (_("Unhandled OSF/1 core file section type %d\n"),
-                                core_scnhdr.scntype);
+         _bfd_error_handler (_("unhandled OSF/1 core file section type %d"),
+                             core_scnhdr.scntype);
          continue;
        }
 
@@ -139,7 +138,7 @@ osf_core_core_file_p (bfd *abfd)
 
   /* OK, we believe you.  You're a core file (sure, sure).  */
 
-  return abfd->xvec;
+  return _bfd_no_cleanup;
 
  fail:
   bfd_release (abfd, core_hdr (abfd));
@@ -174,7 +173,7 @@ swap_abort (void)
 #define        NO_PUT64 ((void (*) (bfd_uint64_t, void *)) swap_abort)
 #define        NO_GETS64 ((bfd_int64_t (*) (const void *)) swap_abort)
 
-const bfd_target osf_core_vec =
+const bfd_target core_osf_vec =
   {
     "osf-core",
     bfd_target_unknown_flavour,
@@ -202,12 +201,16 @@ const bfd_target osf_core_vec =
       osf_core_core_file_p             /* a core file */
     },
     {                          /* bfd_set_format */
-      bfd_false, bfd_false,
-      bfd_false, bfd_false
+      _bfd_bool_bfd_false_error,
+      _bfd_bool_bfd_false_error,
+      _bfd_bool_bfd_false_error,
+      _bfd_bool_bfd_false_error
     },
     {                          /* bfd_write_contents */
-      bfd_false, bfd_false,
-      bfd_false, bfd_false
+      _bfd_bool_bfd_false_error,
+      _bfd_bool_bfd_false_error,
+      _bfd_bool_bfd_false_error,
+      _bfd_bool_bfd_false_error
     },
 
     BFD_JUMP_TABLE_GENERIC (_bfd_generic),
This page took 0.024435 seconds and 4 git commands to generate.