summaryrefslogtreecommitdiffstats
path: root/sys/cddl
diff options
context:
space:
mode:
authorpjd <pjd@FreeBSD.org>2011-10-19 23:33:48 +0000
committerpjd <pjd@FreeBSD.org>2011-10-19 23:33:48 +0000
commit5dc66f9eb55508ef869730ada9c605920bd64f3a (patch)
treee0e8d188fe48293f4fbb566cd42fc3f24b7f02d3 /sys/cddl
parent7523365c00ae5f0cf1142e2e099c7c1307dc544c (diff)
downloadFreeBSD-src-5dc66f9eb55508ef869730ada9c605920bd64f3a.zip
FreeBSD-src-5dc66f9eb55508ef869730ada9c605920bd64f3a.tar.gz
Initialize 'rc' properly before using it. This error could lead to infinite
loop when data reconstruction was needed. MFC after: 3 days
Diffstat (limited to 'sys/cddl')
-rw-r--r--sys/cddl/boot/zfs/zfssubr.c4
1 files changed, 3 insertions, 1 deletions
diff --git a/sys/cddl/boot/zfs/zfssubr.c b/sys/cddl/boot/zfs/zfssubr.c
index 82a09cd..1d655c0 100644
--- a/sys/cddl/boot/zfs/zfssubr.c
+++ b/sys/cddl/boot/zfs/zfssubr.c
@@ -1628,7 +1628,9 @@ reconstruct:
n = 0;
for (c = 0; c < rm->rm_cols; c++) {
- if (rm->rm_col[c].rc_tried)
+ rc = &rm->rm_col[c];
+
+ if (rc->rc_tried)
continue;
cvd = vdev_child(vd, rc->rc_devidx);
OpenPOWER on IntegriCloud