aboutsummaryrefslogtreecommitdiff
path: root/binutils/objcopy.c
diff options
context:
space:
mode:
authorNick Clifton <nickc@redhat.com>2017-03-21 11:48:57 +0000
committerNick Clifton <nickc@redhat.com>2017-03-21 11:48:57 +0000
commit75d7d2986cf896fac8f0690db68ebc552e0b0339 (patch)
tree9fc34a0303c8c4e6f180af7c9d507b1113bac406 /binutils/objcopy.c
parent5badf10a18af78c57dd4ce8e6a6ead7f46e1a878 (diff)
downloadgdb-75d7d2986cf896fac8f0690db68ebc552e0b0339.zip
gdb-75d7d2986cf896fac8f0690db68ebc552e0b0339.tar.gz
gdb-75d7d2986cf896fac8f0690db68ebc552e0b0339.tar.bz2
Update support for GNU BUILD notes so that version notes can contain extra information, and stack protection notes can contain numeric values.
* readelf.c (print_gnu_build_attribute_name): Allow stack protection notes to contain numeric values. Use a colon rather than a space to separate a string name from its values. Decode the numeric value of a stack protection note. * objcopy.c (merge_gnu_build_notes): Allow version notes to contain extra text after the protocol version number.
Diffstat (limited to 'binutils/objcopy.c')
-rw-r--r--binutils/objcopy.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/binutils/objcopy.c b/binutils/objcopy.c
index 868f122..4af4d92 100644
--- a/binutils/objcopy.c
+++ b/binutils/objcopy.c
@@ -1933,7 +1933,7 @@ merge_gnu_build_notes (bfd * abfd, asection * sec, bfd_size_type size, bfd_byte
}
if (pnotes[0].namedata[0] != GNU_BUILD_ATTRIBUTE_TYPE_STRING
- || strcmp (pnotes[0].namedata + 2, "1") != 0)
+ || pnotes[0].namedata[2] != '1')
{
err = _("bad GNU build attribute notes: version note not v1");
goto done;