summaryrefslogtreecommitdiff
path: root/src/conn-tools
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/conn-tools
parentb189876a10023325d28bc439b956ff83dbe51845 (diff)
downloads6-4a90dd1f9063fd5a91431ee6873c25c5c8229805.tar.xz
Port to the new librandom API
Diffstat (limited to 'src/conn-tools')
-rw-r--r--src/conn-tools/s6-accessrules-cdb-from-fs.c4
1 files changed, 3 insertions, 1 deletions
diff --git a/src/conn-tools/s6-accessrules-cdb-from-fs.c b/src/conn-tools/s6-accessrules-cdb-from-fs.c
index 20fef4d..c1aa992 100644
--- a/src/conn-tools/s6-accessrules-cdb-from-fs.c
+++ b/src/conn-tools/s6-accessrules-cdb-from-fs.c
@@ -110,8 +110,10 @@ int main (int argc, char const *const *argv)
int fd ;
PROG = "s6-accessrules-cdb-from-fs" ;
if (argc < 3) strerr_dieusage(100, USAGE) ;
+ if (!random_init())
+ strerr_diefu1sys(111, "init random generator") ;
if (!stralloc_cats(&tmp, argv[1])) return 0 ;
- if (random_sauniquename(&tmp, 8) < 0)
+ if (!random_sauniquename(&tmp, 8))
strerr_diefu1sys(111, "random_sauniquename") ;
if (!stralloc_readyplus(&tmp, 8210))
strerr_diefu1sys(111, "stralloc_catb") ;