svn commit: r354594 - head/stand/libsa/zfs
Toomas Soome
tsoome at FreeBSD.org
Sun Nov 10 15:07:37 UTC 2019
Author: tsoome
Date: Sun Nov 10 15:07:36 2019
New Revision: 354594
URL: https://svnweb.freebsd.org/changeset/base/354594
Log:
loader: use struct initializer in vdev_probe().
Hopefully it is a bit more clear this way.
Modified:
head/stand/libsa/zfs/zfsimpl.c
Modified: head/stand/libsa/zfs/zfsimpl.c
==============================================================================
--- head/stand/libsa/zfs/zfsimpl.c Sun Nov 10 15:03:59 2019 (r354593)
+++ head/stand/libsa/zfs/zfsimpl.c Sun Nov 10 15:07:36 2019 (r354594)
@@ -1697,7 +1697,7 @@ vdev_uberblock_load(vdev_t *vd, uberblock_t *ub)
static int
vdev_probe(vdev_phys_read_t *_read, void *read_priv, spa_t **spap)
{
- vdev_t vtmp;
+ vdev_t vtmp = { 0 };
spa_t *spa;
vdev_t *vdev, *top_vdev, *pool_vdev;
unsigned char *nvlist;
@@ -1713,7 +1713,6 @@ vdev_probe(vdev_phys_read_t *_read, void *read_priv, s
* Load the vdev label and figure out which
* uberblock is most current.
*/
- memset(&vtmp, 0, sizeof(vtmp));
vtmp.v_phys_read = _read;
vtmp.v_read_priv = read_priv;
vtmp.v_psize = P2ALIGN(ldi_get_size(read_priv),
More information about the svn-src-head
mailing list