summaryrefslogtreecommitdiff
path: root/gnu/usr.bin/perl/util.c
diff options
context:
space:
mode:
Diffstat (limited to 'gnu/usr.bin/perl/util.c')
-rw-r--r--gnu/usr.bin/perl/util.c4
1 files changed, 4 insertions, 0 deletions
diff --git a/gnu/usr.bin/perl/util.c b/gnu/usr.bin/perl/util.c
index b64e87dd32f..72af251dd3c 100644
--- a/gnu/usr.bin/perl/util.c
+++ b/gnu/usr.bin/perl/util.c
@@ -4649,6 +4649,9 @@ Perl_parse_unicode_opts(pTHX_ const char **popt)
U32
Perl_seed(pTHX)
{
+#if defined(__OpenBSD__)
+ return arc4random();
+#else
/*
* This is really just a quick hack which grabs various garbage
* values. It really should be a real hash algorithm which
@@ -4717,6 +4720,7 @@ Perl_seed(pTHX)
u += SEED_C5 * (U32)PTR2UV(&when);
#endif
return u;
+#endif
}
void