On Mon, Oct 22, 2018 at 11:54:34PM -0700, Ori Bernstein wrote:
> On Mon, 22 Oct 2018 22:57:39 -0700, Ori Bernstein <[email protected]> wrote:
>
> > While I'm at it, this patch fixes up a few nits around logging, where
> > warn was used instead of warnx, leading to some bogus error strings
> > being printed, and adds a few checks that we should have been doing.
> > This patch also removes a lie in a comment.
> >
> > OK?
>
> And, since there was a request to split the patch, here's the fix,
> isolated from the rest of the changes:
>
Looks good.
OK reyk
> diff --git usr.sbin/vmd/vioqcow2.c usr.sbin/vmd/vioqcow2.c
> index 3a215599d49..d1a00b7acfb 100644
> --- usr.sbin/vmd/vioqcow2.c
> +++ usr.sbin/vmd/vioqcow2.c
> @@ -79,15 +79,15 @@ struct qcdisk {
> int fd;
> uint64_t *l1;
> off_t end;
> - uint32_t clustersz;
> + off_t clustersz;
> off_t disksz; /* In bytes */
> - uint32_t cryptmethod;
> + uint32_t cryptmethod;
>
> uint32_t l1sz;
> off_t l1off;
>
> off_t refoff;
> - uint32_t refsz;
> + off_t refsz;
>
> uint32_t nsnap;
> off_t snapoff;
> @@ -207,7 +207,7 @@ qc2_open(struct qcdisk *disk, int *fds, size_t nfd)
> struct qcheader header;
> uint64_t backingoff;
> uint32_t backingsz;
> - size_t i;
> + off_t i;
> int version, fd;
>
> pthread_rwlock_init(&disk->lock, NULL);
>
> --
> Ori Bernstein
--