diff options
author | Kent Overstreet <kent.overstreet@gmail.com> | 2021-10-19 14:20:50 -0400 |
---|---|---|
committer | Kent Overstreet <kent.overstreet@linux.dev> | 2023-10-22 17:09:14 -0400 |
commit | d355c6f4f73060c8f3eba95b9ae72929669f7516 (patch) | |
tree | 0ab609144ad249bad0aa6087989f21070845db6c /fs/bcachefs/debug.c | |
parent | dfc276df911cb7bf026482a9af7c30a60726daff (diff) |
bcachefs: for_each_btree_node() now returns errors directly
This changes for_each_btree_node() to work like for_each_btree_key(),
and to that end bch2_btree_iter_peek_node() and next_node() also return
error ptrs.
Signed-off-by: Kent Overstreet <kent.overstreet@gmail.com>
Diffstat (limited to 'fs/bcachefs/debug.c')
-rw-r--r-- | fs/bcachefs/debug.c | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/fs/bcachefs/debug.c b/fs/bcachefs/debug.c index 5ffb7f0a3bf6..8b25ef9e1e05 100644 --- a/fs/bcachefs/debug.c +++ b/fs/bcachefs/debug.c @@ -318,7 +318,7 @@ static ssize_t bch2_read_btree_formats(struct file *file, char __user *buf, bch2_trans_init(&trans, i->c, 0, 0); - for_each_btree_node(&trans, iter, i->id, i->from, 0, b) { + for_each_btree_node(&trans, iter, i->id, i->from, 0, b, err) { bch2_btree_node_to_text(&PBUF(i->buf), i->c, b); i->bytes = strlen(i->buf); err = flush_buf(i); |