From b9291affaa4576762c30fb31083f33f5d745dea1 Mon Sep 17 00:00:00 2001 From: Alexander Block Date: Sat, 28 Jul 2012 11:07:18 +0200 Subject: Btrfs: add missing check for dir != tmp_dir to is_first_ref We missed that check which resultet in all refs with the same name being reported as first_ref. Reported-by: Alex Lyakas Signed-off-by: Alexander Block --- fs/btrfs/send.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'fs/btrfs') diff --git a/fs/btrfs/send.c b/fs/btrfs/send.c index a5fae484d4e1..bea5b4378cc5 100644 --- a/fs/btrfs/send.c +++ b/fs/btrfs/send.c @@ -1589,7 +1589,7 @@ static int is_first_ref(struct send_ctx *sctx, if (ret < 0) goto out; - if (name_len != fs_path_len(tmp_name)) { + if (dir != tmp_dir || name_len != fs_path_len(tmp_name)) { ret = 0; goto out; } -- cgit v1.2.3