Source-Changes-HG archive
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index][Old Index]
[src/trunk]: src/sys/dev/scsipi Don't return EPASSTHROUGH when succeeding in ...
details: https://anonhg.NetBSD.org/src/rev/1b8dd611f777
branches: trunk
changeset: 790219:1b8dd611f777
user: skrll <skrll%NetBSD.org@localhost>
date: Sat Sep 28 09:00:26 2013 +0000
description:
Don't return EPASSTHROUGH when succeeding in ODIOCGDINFO or ODIOCGDEFLABEL
diffstat:
sys/dev/scsipi/cd.c | 7 ++++---
1 files changed, 4 insertions(+), 3 deletions(-)
diffs (35 lines):
diff -r 0f1a51d5ca4c -r 1b8dd611f777 sys/dev/scsipi/cd.c
--- a/sys/dev/scsipi/cd.c Sat Sep 28 07:29:17 2013 +0000
+++ b/sys/dev/scsipi/cd.c Sat Sep 28 09:00:26 2013 +0000
@@ -1,4 +1,4 @@
-/* $NetBSD: cd.c,v 1.313 2013/09/12 12:26:13 martin Exp $ */
+/* $NetBSD: cd.c,v 1.314 2013/09/28 09:00:26 skrll Exp $ */
/*-
* Copyright (c) 1998, 2001, 2003, 2004, 2005, 2008 The NetBSD Foundation,
@@ -50,7 +50,7 @@
*/
#include <sys/cdefs.h>
-__KERNEL_RCSID(0, "$NetBSD: cd.c,v 1.313 2013/09/12 12:26:13 martin Exp $");
+__KERNEL_RCSID(0, "$NetBSD: cd.c,v 1.314 2013/09/28 09:00:26 skrll Exp $");
#include <sys/param.h>
#include <sys/systm.h>
@@ -1246,7 +1246,7 @@
struct scsipi_periph *periph = cd->sc_periph;
struct cd_formatted_toc toc;
int part = CDPART(dev);
- int error = 0;
+ int error;
int s;
#ifdef __HAVE_OLD_DISKLABEL
struct disklabel *newlabel = NULL;
@@ -1305,6 +1305,7 @@
if (error != EPASSTHROUGH)
return (error);
+ error = 0;
switch (cmd) {
case DIOCGDINFO:
*(struct disklabel *)addr = *(cd->sc_dk.dk_label);
Home |
Main Index |
Thread Index |
Old Index