Use unique_xmalloc_ptr in fixup_go_packaging
[deliverable/binutils-gdb.git] / bfd / mach-o-aarch64.c
index 12fc47eb0a33723af003edf36e1bba9cf3e16904..f3406b3be25eade0ccde817ab741b6c95c93b3e2 100644 (file)
@@ -1,5 +1,5 @@
 /* AArch-64 Mach-O support for BFD.
-   Copyright (C) 2015-2017 Free Software Foundation, Inc.
+   Copyright (C) 2015-2020 Free Software Foundation, Inc.
 
    This file is part of BFD, the Binary File Descriptor library.
 
    MA 02110-1301, USA.  */
 
 #include "sysdep.h"
-#include "mach-o.h"
 #include "bfd.h"
 #include "libbfd.h"
 #include "libiberty.h"
+#include "mach-o.h"
 #include "mach-o/arm64.h"
 
 #define bfd_mach_o_object_p bfd_mach_o_arm64_object_p
@@ -50,7 +50,7 @@ static const bfd_target *
 bfd_mach_o_arm64_core_p (bfd *abfd)
 {
   return bfd_mach_o_header_p (abfd, 0,
-                              BFD_MACH_O_MH_CORE, BFD_MACH_O_CPU_TYPE_ARM64);
+                             BFD_MACH_O_MH_CORE, BFD_MACH_O_CPU_TYPE_ARM64);
 }
 
 static bfd_boolean
@@ -147,9 +147,11 @@ static reloc_howto_type arm64_howto_table[]=
 };
 
 static bfd_boolean
-bfd_mach_o_arm64_canonicalize_one_reloc (bfd *abfd,
-                                      struct mach_o_reloc_info_external *raw,
-                                        arelent *res, asymbol **syms)
+bfd_mach_o_arm64_canonicalize_one_reloc (bfd *       abfd,
+                                        struct mach_o_reloc_info_external * raw,
+                                        arelent *   res,
+                                        asymbol **  syms,
+                                        arelent *   res_base ATTRIBUTE_UNUSED)
 {
   bfd_mach_o_reloc_info reloc;
 
@@ -211,18 +213,18 @@ bfd_mach_o_arm64_canonicalize_one_reloc (bfd *abfd,
       break;
     case BFD_MACH_O_ARM64_RELOC_SUBTRACTOR:
       if (reloc.r_pcrel)
-        return FALSE;
+       return FALSE;
       switch (reloc.r_length)
-        {
-        case 2:
-          res->howto = &arm64_howto_table[11];
-          return TRUE;
-        case 3:
-          res->howto = &arm64_howto_table[12];
-          return TRUE;
-        default:
-          return FALSE;
-        }
+       {
+       case 2:
+         res->howto = &arm64_howto_table[11];
+         return TRUE;
+       case 3:
+         res->howto = &arm64_howto_table[12];
+         return TRUE;
+       default:
+         return FALSE;
+       }
       break;
     case BFD_MACH_O_ARM64_RELOC_BRANCH26:
       if (reloc.r_length == 2 && reloc.r_pcrel == 1)
@@ -293,12 +295,12 @@ bfd_mach_o_arm64_bfd_reloc_name_lookup (bfd *abfd ATTRIBUTE_UNUSED,
   return NULL;
 }
 
-#define TARGET_NAME            aarch64_mach_o_vec
-#define TARGET_STRING          "mach-o-arm64"
+#define TARGET_NAME            aarch64_mach_o_vec
+#define TARGET_STRING          "mach-o-arm64"
 #define TARGET_ARCHITECTURE    bfd_arch_aarch64
 #define TARGET_PAGESIZE                4096
-#define TARGET_BIG_ENDIAN      0
-#define TARGET_ARCHIVE                 0
+#define TARGET_BIG_ENDIAN      0
+#define TARGET_ARCHIVE         0
 #define TARGET_PRIORITY                0
 #include "mach-o-target.c"
 
This page took 0.026695 seconds and 4 git commands to generate.