summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorpatrick <patrick@openbsd.org>2020-05-29 20:35:56 +0000
committerpatrick <patrick@openbsd.org>2020-05-29 20:35:56 +0000
commit366d1594d1d2482544444fba25b36f7129164430 (patch)
treec21de442fae87883ff81d857a36f8410d013816f
parentsync (diff)
downloadwireguard-openbsd-366d1594d1d2482544444fba25b36f7129164430.tar.xz
wireguard-openbsd-366d1594d1d2482544444fba25b36f7129164430.zip
Adjust some PPC ELF code to return -1 instead of doing pointer
arithmetics on NULL, like we did in r1.21 on elflink.c, to stop clang from complaining when setting up a cross-toolchain. ok kettenis@
-rw-r--r--gnu/usr.bin/binutils-2.17/bfd/elf64-ppc.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/gnu/usr.bin/binutils-2.17/bfd/elf64-ppc.c b/gnu/usr.bin/binutils-2.17/bfd/elf64-ppc.c
index 33327f44cba..8f932305755 100644
--- a/gnu/usr.bin/binutils-2.17/bfd/elf64-ppc.c
+++ b/gnu/usr.bin/binutils-2.17/bfd/elf64-ppc.c
@@ -4112,7 +4112,7 @@ ppc64_elf_archive_symbol_lookup (bfd *abfd,
len = strlen (name);
dot_name = bfd_alloc (abfd, len + 2);
if (dot_name == NULL)
- return (struct elf_link_hash_entry *) 0 - 1;
+ return (struct elf_link_hash_entry *) -1;
dot_name[0] = '.';
memcpy (dot_name + 1, name, len + 1);
h = _bfd_elf_archive_symbol_lookup (abfd, info, dot_name);