Commit 0c04f5eb authored by Kent Overstreet's avatar Kent Overstreet Committed by Kent Overstreet

bcachefs: Don't overflow trans with iters from triggers

Signed-off-by: default avatarKent Overstreet <kent.overstreet@linux.dev>
parent 8d591d5d
...@@ -1359,6 +1359,8 @@ static int trans_get_key(struct btree_trans *trans, ...@@ -1359,6 +1359,8 @@ static int trans_get_key(struct btree_trans *trans,
if (IS_ERR(*iter)) if (IS_ERR(*iter))
return PTR_ERR(*iter); return PTR_ERR(*iter);
bch2_trans_iter_free_on_commit(trans, *iter);
*k = bch2_btree_iter_peek_slot(*iter); *k = bch2_btree_iter_peek_slot(*iter);
ret = bkey_err(*k); ret = bkey_err(*k);
if (ret) if (ret)
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment