Re: [PATCH 07/15] btrfs-progs: fix endian bugs in chunk rebuilding

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



On Wed, Aug 14, 2013 at 04:16:37PM -0700, Zach Brown wrote:
> I *think* the second one is just a typo.  The chunk's num_stripes was
> already initialized from the record, but it's le16.  So we'll set the
> item's size based on the record's native num_stripes.

> @@ -1117,7 +1117,7 @@ static int __rebuild_chunk_items(struct btrfs_trans_handle *trans,
>  		key.offset = chunk_rec->offset;
>  
>  		ret = btrfs_insert_item(trans, chunk_root, &key, chunk,
> -				btrfs_chunk_item_size(chunk->num_stripes));
> +				btrfs_chunk_item_size(chunk_rec->num_stripes));

AFAICS, this is an equivalent change, chunk gets copied from chunk_rec
via create_chunk_item a few lines above. It looks more consistent with
chunk_rec, though.

>  		free(chunk);
>  		if (ret)
>  			return ret;
--
To unsubscribe from this list: send the line "unsubscribe linux-btrfs" in
the body of a message to majordomo@xxxxxxxxxxxxxxx
More majordomo info at  http://vger.kernel.org/majordomo-info.html




[Index of Archives]     [Linux Filesystem Development]     [Linux NFS]     [Linux NILFS]     [Linux USB Devel]     [Linux Audio Users]     [Yosemite News]     [Linux Kernel]     [Linux SCSI]

  Powered by Linux