svn commit: r279673 - head/usr.sbin/bhyve
Alexander Motin
mav at FreeBSD.org
Thu Mar 5 20:24:35 UTC 2015
Author: mav
Date: Thu Mar 5 20:24:34 2015
New Revision: 279673
URL: https://svnweb.freebsd.org/changeset/base/279673
Log:
Fix error translation broken in r279658.
Reported by: grehan
MFC after: 2 weeks
Modified:
head/usr.sbin/bhyve/pci_virtio_block.c
Modified: head/usr.sbin/bhyve/pci_virtio_block.c
==============================================================================
--- head/usr.sbin/bhyve/pci_virtio_block.c Thu Mar 5 20:22:28 2015 (r279672)
+++ head/usr.sbin/bhyve/pci_virtio_block.c Thu Mar 5 20:24:34 2015 (r279673)
@@ -246,12 +246,11 @@ pci_vtblk_proc(struct pci_vtblk_softc *s
}
/* convert errno into a virtio block error return */
- if (err < 0) {
- if (err == -ENOSYS)
- *status = VTBLK_S_UNSUPP;
- else
- *status = VTBLK_S_IOERR;
- } else
+ if (err == -ENOSYS)
+ *status = VTBLK_S_UNSUPP;
+ else if (err != 0)
+ *status = VTBLK_S_IOERR;
+ else
*status = VTBLK_S_OK;
/*
More information about the svn-src-head
mailing list