summaryrefslogtreecommitdiff
path: root/sys
diff options
context:
space:
mode:
authorkstailey <kstailey@cvs.openbsd.org>1997-01-15 22:33:54 +0000
committerkstailey <kstailey@cvs.openbsd.org>1997-01-15 22:33:54 +0000
commit53cd0dbd9b67615e4a739ea2cafae651aa087441 (patch)
tree7c16f6474d7f6e8e1d7a7dfcffdd0f1e62fa4923 /sys
parentbcc3c160886ff1ad4bd9319421220b10a60aa57e (diff)
moved init of ret in randomioctl() to better location
Diffstat (limited to 'sys')
-rw-r--r--sys/dev/rnd.c5
1 files changed, 3 insertions, 2 deletions
diff --git a/sys/dev/rnd.c b/sys/dev/rnd.c
index 2e446924dc5..7d915b6fa57 100644
--- a/sys/dev/rnd.c
+++ b/sys/dev/rnd.c
@@ -1,4 +1,4 @@
-/* $OpenBSD: rnd.c,v 1.15 1997/01/15 02:03:53 kstailey Exp $ */
+/* $OpenBSD: rnd.c,v 1.16 1997/01/15 22:33:53 kstailey Exp $ */
/*
* random.c -- A strong random number generator
@@ -820,7 +820,7 @@ randomioctl(dev, cmd, data, flag, p)
int flag;
struct proc *p;
{
- int ret = 0;
+ int ret;
u_int cnt;
switch (cmd) {
@@ -835,6 +835,7 @@ randomioctl(dev, cmd, data, flag, p)
random_state.entropy_count += cnt;
if (random_state.entropy_count > POOLBITS)
random_state.entropy_count = POOLBITS;
+ ret = 0;
break;
case RNDZAPENTCNT:
if (suser(p->p_ucred, &p->p_acflag) != 0)