about summary refs log tree commit diff
path: root/src/libs6/s6-ftrigrd.c
diff options
context:
space:
mode:
authorLaurent Bercot <ska-skaware@skarnet.org>2016-10-14 17:16:43 +0000
committerLaurent Bercot <ska-skaware@skarnet.org>2016-10-14 17:16:43 +0000
commit4a90dd1f9063fd5a91431ee6873c25c5c8229805 (patch)
tree8c15b69aaa7f3c56ad60100463c3769f8f7ae4e4 /src/libs6/s6-ftrigrd.c
parentb189876a10023325d28bc439b956ff83dbe51845 (diff)
downloads6-4a90dd1f9063fd5a91431ee6873c25c5c8229805.tar.gz
s6-4a90dd1f9063fd5a91431ee6873c25c5c8229805.tar.xz
s6-4a90dd1f9063fd5a91431ee6873c25c5c8229805.zip
Port to the new librandom API
Diffstat (limited to 'src/libs6/s6-ftrigrd.c')
-rw-r--r--src/libs6/s6-ftrigrd.c3
1 files changed, 3 insertions, 0 deletions
diff --git a/src/libs6/s6-ftrigrd.c b/src/libs6/s6-ftrigrd.c
index b4c4c86..3200300 100644
--- a/src/libs6/s6-ftrigrd.c
+++ b/src/libs6/s6-ftrigrd.c
@@ -13,6 +13,7 @@
 #include <skalibs/stralloc.h>
 #include <skalibs/sig.h>
 #include <skalibs/tai.h>
+#include <skalibs/random.h>
 #include <skalibs/djbunix.h>
 #include <skalibs/iopause.h>
 #include <skalibs/unixmessage.h>
@@ -194,6 +195,8 @@ int main (void)
   if (ndelay_on(0) < 0) strerr_diefu2sys(111, "ndelay_on ", "0") ;
   if (ndelay_on(1) < 0) strerr_diefu2sys(111, "ndelay_on ", "1") ;
   if (sig_ignore(SIGPIPE) < 0) strerr_diefu1sys(111, "ignore SIGPIPE") ;
+  if (!random_init())
+    strerr_diefu1sys(111, "init random generator") ;
 
   {
     tain_t deadline ;