summaryrefslogtreecommitdiff
path: root/bfd/elf64-ppc.c
diff options
context:
space:
mode:
Diffstat (limited to 'bfd/elf64-ppc.c')
-rw-r--r--bfd/elf64-ppc.c6
1 files changed, 3 insertions, 3 deletions
diff --git a/bfd/elf64-ppc.c b/bfd/elf64-ppc.c
index bc8dc4df1a..c306954dac 100644
--- a/bfd/elf64-ppc.c
+++ b/bfd/elf64-ppc.c
@@ -2042,8 +2042,8 @@ ppc64_elf_section_flags (const Elf_Internal_Shdr *hdr)
{
const char *name = hdr->bfd_section->name;
- if (strncmp (name, ".sbss", 5) == 0
- || strncmp (name, ".sdata", 6) == 0)
+ if (startswith (name, ".sbss")
+ || startswith (name, ".sdata"))
hdr->bfd_section->flags |= SEC_SMALL_DATA;
return true;
@@ -15873,7 +15873,7 @@ ppc64_elf_relocate_section (bfd *output_bfd,
if (*name == '.')
++name;
- if (strncmp (name, "__libc_start_main", 17) == 0
+ if (startswith (name, "__libc_start_main")
&& (name[17] == 0 || name[17] == '@'))
{
/* Allow crt1 branch to go via a toc adjusting