bhyve: replace uninitialized variable "offset".

Use io->io_req.br_offset instead.

Suggested by:	grehan
CID:		1288937
This commit is contained in:
Pedro F. Giffuni 2016-05-13 14:38:04 +00:00
parent fdddd267d7
commit 40dbeed32b
Notes: svn2git 2020-12-20 02:59:44 +00:00
svn path=/head/; revision=299675

View File

@ -200,7 +200,6 @@ pci_vtblk_proc(struct pci_vtblk_softc *sc, struct vqueue_info *vq)
int err;
ssize_t iolen;
int writeop, type;
off_t offset;
struct iovec iov[BLOCKIF_IOV_MAX + 2];
uint16_t idx, flags[BLOCKIF_IOV_MAX + 2];
@ -249,7 +248,8 @@ pci_vtblk_proc(struct pci_vtblk_softc *sc, struct vqueue_info *vq)
io->io_req.br_resid = iolen;
DPRINTF(("virtio-block: %s op, %zd bytes, %d segs, offset %ld\n\r",
writeop ? "write" : "read/ident", iolen, i - 1, offset));
writeop ? "write" : "read/ident", iolen, i - 1,
io->io_req.br_offset));
switch (type) {
case VBH_OP_READ: