summaryrefslogtreecommitdiffstats
path: root/sys/kern/subr_disk.c
diff options
context:
space:
mode:
authorkrw <krw@openbsd.org>2015-12-24 20:14:07 +0000
committerkrw <krw@openbsd.org>2015-12-24 20:14:07 +0000
commit0343e5af8158a83d2a7e462c992cf83d57b7eb70 (patch)
tree69b28effc89b59c5eab7e5b7b3539dc099a7009e /sys/kern/subr_disk.c
parentBoth our manual and POSIX ask us to set the error indicator when an (diff)
downloadwireguard-openbsd-0343e5af8158a83d2a7e462c992cf83d57b7eb70.tar.xz
wireguard-openbsd-0343e5af8158a83d2a7e462c992cf83d57b7eb70.zip
Make gpt_chk_mbr() instances even more identicaller by always
returning 0 or 1 since only boolean checks of the result are done. No need for EINVAL as a return value.
Diffstat (limited to 'sys/kern/subr_disk.c')
-rw-r--r--sys/kern/subr_disk.c4
1 files changed, 2 insertions, 2 deletions
diff --git a/sys/kern/subr_disk.c b/sys/kern/subr_disk.c
index 38babce4e30..238573f7369 100644
--- a/sys/kern/subr_disk.c
+++ b/sys/kern/subr_disk.c
@@ -1,4 +1,4 @@
-/* $OpenBSD: subr_disk.c,v 1.221 2015/12/24 18:03:03 krw Exp $ */
+/* $OpenBSD: subr_disk.c,v 1.222 2015/12/24 20:14:07 krw Exp $ */
/* $NetBSD: subr_disk.c,v 1.17 1996/03/16 23:17:08 christos Exp $ */
/*
@@ -615,7 +615,7 @@ gpt_chk_mbr(struct dos_partition *dp, u_int64_t dsize)
if (found == 1 && efi == 1)
return (0);
- return (EINVAL);
+ return (1);
}
int