elf: Parse the auxv values as unsigned on tst-tunables-enable_secure-env.c (BZ 31890)

AT_HWCAP on some architecture can indeed use all bits.

Checked on x86_64-linux-gnu and powerpc-linux-gnu.
Reviewed-By: Andreas K. Hüttel <dilfridge@gentoo.org>
This commit is contained in:
Adhemerval Zanella 2024-07-18 09:15:44 -03:00
parent 66f2cd6e1a
commit 3c354d62f5

View File

@ -46,7 +46,7 @@ check_auxv (unsigned long type, char *argv)
{
char *endptr;
errno = 0;
unsigned long int varg = strtol (argv, &endptr, 10);
unsigned long int varg = strtoul (argv, &endptr, 10);
TEST_VERIFY_EXIT (errno == 0);
TEST_VERIFY_EXIT (*endptr == '\0');
errno = 0;