summaryrefslogtreecommitdiff
path: root/regress/sys
diff options
context:
space:
mode:
Diffstat (limited to 'regress/sys')
-rw-r--r--regress/sys/kern/kqueue/kqueue-random.c5
1 files changed, 3 insertions, 2 deletions
diff --git a/regress/sys/kern/kqueue/kqueue-random.c b/regress/sys/kern/kqueue/kqueue-random.c
index 55ac3865c01..fe7c7f295c2 100644
--- a/regress/sys/kern/kqueue/kqueue-random.c
+++ b/regress/sys/kern/kqueue/kqueue-random.c
@@ -1,4 +1,4 @@
-/* $OpenBSD: kqueue-random.c,v 1.6 2011/07/06 05:32:04 guenther Exp $ */
+/* $OpenBSD: kqueue-random.c,v 1.7 2011/07/07 01:42:05 guenther Exp $ */
/* Written by Michael Shalayeff, 2002, Public Domain */
#include <stdlib.h>
@@ -58,9 +58,10 @@ do_random(void)
}
n = MIN((ev.data + 7) / 8, sizeof(buf));
- if (read(fd, buf, n) < 1)
+ if (read(fd, buf, n) < 1) {
warnx("read %d", n);
return (1);
+ }
close(kq);
close(fd);