1
0
mirror of https://sourceware.org/git/glibc.git synced 2025-07-29 11:41:21 +03:00

Linux: getrandom syscall number is always available

Due to the built-in tables, __NR_getrandom is always defined.

Reviewed-by: Adhemerval Zanella <adhemerval.zanella@linaro.org>
This commit is contained in:
Florian Weimer
2020-03-03 12:15:38 +01:00
parent d241dee4dd
commit 658b5848a8
2 changed files with 0 additions and 22 deletions

View File

@ -21,7 +21,6 @@
#include <errno.h>
#include <unistd.h>
#ifdef __NR_getrandom
/* Write LENGTH bytes of randomness starting at BUFFER. Return 0 on
success and -1 on failure. */
int
@ -63,11 +62,3 @@ getentropy (void *buffer, size_t length)
}
return 0;
}
#else
int
getentropy (void *buffer, size_t length)
{
__set_errno (ENOSYS);
return -1;
}
#endif