svn commit: r348471 - head/stand/libsa/zfs
Kyle Evans
kevans at FreeBSD.org
Fri May 31 17:44:23 UTC 2019
Author: kevans
Date: Fri May 31 17:44:22 2019
New Revision: 348471
URL: https://svnweb.freebsd.org/changeset/base/348471
Log:
stand: zfs: Free bouncebuf on error path in vdev_read
r344226 inadvertently added this path in which we return from failure on an
lseek and do not free bouncebuf on the way out.
MFC after: 3 days
Modified:
head/stand/libsa/zfs/zfs.c
Modified: head/stand/libsa/zfs/zfs.c
==============================================================================
--- head/stand/libsa/zfs/zfs.c Fri May 31 17:18:09 2019 (r348470)
+++ head/stand/libsa/zfs/zfs.c Fri May 31 17:44:22 2019 (r348471)
@@ -425,8 +425,10 @@ vdev_read(vdev_t *vdev, void *priv, off_t offset, void
}
}
- if (lseek(fd, start_sec * secsz, SEEK_SET) == -1)
- return (errno);
+ if (lseek(fd, start_sec * secsz, SEEK_SET) == -1) {
+ ret = errno;
+ goto error;
+ }
/* Partial data return from first sector */
if (head > 0) {
More information about the svn-src-all
mailing list