summaryrefslogtreecommitdiff
path: root/print-tree.c
diff options
context:
space:
mode:
authorDavid Sterba <dsterba@suse.com>2017-09-23 20:45:24 +0200
committerDavid Sterba <dsterba@suse.com>2017-09-25 15:18:19 +0200
commit510a282f7f17ec3541a0f6845cb100847aa6857f (patch)
treeccda3a257c29ea05f3a5d83668df89ad3947e00d /print-tree.c
parent8eccfa86c0c7f1645556a119d8b217d7173af10d (diff)
btrfs-progs: print-tree: use proper helper for reading offset
Sparse warns print-tree.c:1261:49: warning: incorrect type in argument 4 (different base types) print-tree.c:1261:49: expected unsigned long long [unsigned] [usertype] start print-tree.c:1261:49: got restricted __le64 [addressable] [usertype] offset which means we have to use the helper instead of directly accessing the offset member. This could print bogus number on bigendian arch. Signed-off-by: David Sterba <dsterba@suse.com>
Diffstat (limited to 'print-tree.c')
-rw-r--r--print-tree.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/print-tree.c b/print-tree.c
index cbed541a..3c585e31 100644
--- a/print-tree.c
+++ b/print-tree.c
@@ -1258,7 +1258,7 @@ void btrfs_print_leaf(struct btrfs_root *root, struct extent_buffer *eb)
break;
case BTRFS_EXTENT_CSUM_KEY:
print_extent_csum(eb, root->fs_info, item_size,
- disk_key.offset);
+ offset);
break;
case BTRFS_EXTENT_DATA_KEY:
print_file_extent_item(eb, item, i, ptr);