[PATCH binutils 1/4] aarch64: add STO_AARCH64_VARIANT_PCS and DT_AARCH64_VARIANT_PCS
Nick Clifton
nickc@redhat.com
Fri May 24 10:24:00 GMT 2019
Hi Szabolcs,
A little bit of paranoia...
> +static const char *
> +get_aarch64_symbol_other (unsigned int other)
> +{
> + static char buf[32];
> +
> + if (other & STO_AARCH64_VARIANT_PCS)
> + {
> + other &= ~STO_AARCH64_VARIANT_PCS;
> + if (other == 0)
> + return "VARIANT_PCS";
> + snprintf (buf, sizeof buf, "VARIANT_PCS | %x", other);
> + return buf;
On a host where an unsigned int is a 64-bit quantity, it is
theoretically possible for the snprintf function to have to
truncate the output, possibly confusing the user. Could you
increase the buffer size a little bit please ?
Cheers
Nick
More information about the Binutils
mailing list