Source-Changes-HG archive
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index][Old Index]
[src/trunk]: src/sys/dev size routine returns -1 on error, not an error code.
details: https://anonhg.NetBSD.org/src/rev/c732db102c38
branches: trunk
changeset: 349171:c732db102c38
user: mlelstv <mlelstv%NetBSD.org@localhost>
date: Sat Nov 26 12:32:03 2016 +0000
description:
size routine returns -1 on error, not an error code.
diffstat:
sys/dev/ld.c | 8 ++++----
1 files changed, 4 insertions(+), 4 deletions(-)
diffs (32 lines):
diff -r 4f71f9d7a1ca -r c732db102c38 sys/dev/ld.c
--- a/sys/dev/ld.c Sat Nov 26 11:36:38 2016 +0000
+++ b/sys/dev/ld.c Sat Nov 26 12:32:03 2016 +0000
@@ -1,4 +1,4 @@
-/* $NetBSD: ld.c,v 1.98 2016/10/11 18:31:11 jdolecek Exp $ */
+/* $NetBSD: ld.c,v 1.99 2016/11/26 12:32:03 mlelstv Exp $ */
/*-
* Copyright (c) 1998, 2000 The NetBSD Foundation, Inc.
@@ -34,7 +34,7 @@
*/
#include <sys/cdefs.h>
-__KERNEL_RCSID(0, "$NetBSD: ld.c,v 1.98 2016/10/11 18:31:11 jdolecek Exp $");
+__KERNEL_RCSID(0, "$NetBSD: ld.c,v 1.99 2016/11/26 12:32:03 mlelstv Exp $");
#include <sys/param.h>
#include <sys/systm.h>
@@ -444,11 +444,11 @@
unit = DISKUNIT(dev);
if ((sc = device_lookup_private(&ld_cd, unit)) == NULL)
- return (ENODEV);
+ return (-1);
dksc = &sc->sc_dksc;
if ((sc->sc_flags & LDF_ENABLED) == 0)
- return (ENODEV);
+ return (-1);
return dk_size(dksc, dev);
}
Home |
Main Index |
Thread Index |
Old Index