Commit: Fix GOLD testsuite failures for 2.35 branch
Hans-Peter Nilsson
hp@bitrange.com
Mon Jul 6 11:51:35 GMT 2020
On Mon, 6 Jul 2020, Nick Clifton via Binutils wrote:
> - || strncmp(name, ".gnu.build.attributes", 21) == 0
> +#define ATTR_SECTION_PREFIX ".gnu.build.attributes"
> + || strncmp(name, ATTR_SECTION_PREFIX, sizeof ATTR_SECTION_PREFIX) == 0
Beware: not the same thing. Use strlen (which likely is
constant-folded to 21), not sizeof (which counts the nil; 22).
brgds, H-P
More information about the Binutils
mailing list