zfs/lib/libzfs
Ned Bass 858219cc4e Fix missing vdev names in zpool status output
Top-level vdev names in zpool status output should follow a <type-id> naming
convention.  In the case of raidz devices, the type portion of the name was
missing.

This commit fixes a bug in zpool_vdev_name() where in this snprintf call

	(void) snprintf(buf, sizeof (buf), "%s-%llu", path,
		(u_longlong_t)id);

buf and path may point to the same location.  The result is that buf ends up
containing only the "-id" part.  This only occurred for raidz devices because
the code for appending the parity level to the type string stored its result in
buf then set path to point there.  To fix this we allocate a new temporary
buffer on the stack instead of reusing buf.

Signed-off-by: Brian Behlendorf <behlendorf1@llnl.gov>
Closes #57
2010-09-23 12:14:06 -07:00
..
Makefile.am Support custom build directories and move includes 2010-09-08 12:38:56 -07:00
Makefile.in Support custom build directories and move includes 2010-09-08 12:38:56 -07:00
libzfs_changelist.c Add linux user disk support 2010-08-31 13:42:00 -07:00
libzfs_config.c Fix gcc missing braces warnings 2010-08-27 15:34:03 -07:00
libzfs_dataset.c Add linux user disk support 2010-08-31 13:42:00 -07:00
libzfs_diff.c Add linux compatibility 2010-08-31 13:41:59 -07:00
libzfs_fru.c Add linux topology support 2010-08-31 13:42:00 -07:00
libzfs_graph.c Fix gcc missing braces warnings 2010-08-27 15:34:03 -07:00
libzfs_import.c Add linux user disk support 2010-08-31 13:42:00 -07:00
libzfs_mount.c Add linux user disk support 2010-08-31 13:42:00 -07:00
libzfs_pool.c Fix missing vdev names in zpool status output 2010-09-23 12:14:06 -07:00
libzfs_sendrecv.c Add linux user util support 2010-08-31 13:42:01 -07:00
libzfs_status.c Update core ZFS code from build 121 to build 141. 2010-05-28 13:45:14 -07:00
libzfs_util.c Add linux user util support 2010-08-31 13:42:01 -07:00