diff options
Diffstat (limited to 'src/librandom/unidevurandom.c')
-rw-r--r-- | src/librandom/unidevurandom.c | 38 |
1 files changed, 0 insertions, 38 deletions
diff --git a/src/librandom/unidevurandom.c b/src/librandom/unidevurandom.c deleted file mode 100644 index d601ea0..0000000 --- a/src/librandom/unidevurandom.c +++ /dev/null @@ -1,38 +0,0 @@ -/* ISC license. */ - -#include <skalibs/sysdeps.h> -#include <skalibs/unirandomdev.h> -#include <skalibs/unirandom.h> - -#ifdef SKALIBS_HASDEVURANDOM - -#include "random-internal.h" - -int unidevurandom_init (union unirandominfo *u) -{ - return unirandomdev_sinit(u, "/dev/urandom") ; -} - -int unirandom_register_devurandom (unirandom *u) -{ - unirandom_register(u, &unidevurandom_init, &unirandomdev_finish, &unirandomdev_readb, &unirandomdev_readnb) ; - return 1 ; -} - -#else - -#include <errno.h> - -int unidevurandom_init (union unirandominfo *u) -{ - (void)u ; - return (errno = ENOSYS, 0) ; -} - -int unirandom_register_devurandom (unirandom *u) -{ - (void)u ; - return (errno = ENOSYS, 0) ; -} - -#endif |