blob: 155d4258c4ed1847ccfad101299b34ed3087989f (
plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
|
#include <errno.h>
#include <libc.h>
unsigned long getauxval(unsigned long type)
{
size_t *auxv = __libc.auxv;
while (*auxv) {
if (*auxv == type)
return auxv[1];
auxv += 2;
}
errno = ENOENT;
return 0;
}
|