diff options
Diffstat (limited to 'fs/bcachefs/dirent.c')
-rw-r--r-- | fs/bcachefs/dirent.c | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/fs/bcachefs/dirent.c b/fs/bcachefs/dirent.c index 288f46b55876..c2126f39369b 100644 --- a/fs/bcachefs/dirent.c +++ b/fs/bcachefs/dirent.c @@ -350,8 +350,8 @@ int bch2_dirent_rename(struct btree_trans *trans, bkey_init(&new_src->k); new_src->k.p = src_iter.pos; - if (bkey_cmp(dst_pos, src_iter.pos) <= 0 && - bkey_cmp(src_iter.pos, dst_iter.pos) < 0) { + if (bkey_le(dst_pos, src_iter.pos) && + bkey_lt(src_iter.pos, dst_iter.pos)) { /* * We have a hash collision for the new dst key, * and new_src - the key we're deleting - is between |