diff options
Diffstat (limited to 'fs/btrfs/send.c')
-rw-r--r-- | fs/btrfs/send.c | 8 |
1 files changed, 5 insertions, 3 deletions
diff --git a/fs/btrfs/send.c b/fs/btrfs/send.c index aa72bfd28f7d..a739b825bdd3 100644 --- a/fs/btrfs/send.c +++ b/fs/btrfs/send.c | |||
@@ -1920,10 +1920,12 @@ static int did_overwrite_ref(struct send_ctx *sctx, | |||
1920 | /* | 1920 | /* |
1921 | * We know that it is or will be overwritten. Check this now. | 1921 | * We know that it is or will be overwritten. Check this now. |
1922 | * The current inode being processed might have been the one that caused | 1922 | * The current inode being processed might have been the one that caused |
1923 | * inode 'ino' to be orphanized, therefore ow_inode can actually be the | 1923 | * inode 'ino' to be orphanized, therefore check if ow_inode matches |
1924 | * same as sctx->send_progress. | 1924 | * the current inode being processed. |
1925 | */ | 1925 | */ |
1926 | if (ow_inode <= sctx->send_progress) | 1926 | if ((ow_inode < sctx->send_progress) || |
1927 | (ino != sctx->cur_ino && ow_inode == sctx->cur_ino && | ||
1928 | gen == sctx->cur_inode_gen)) | ||
1927 | ret = 1; | 1929 | ret = 1; |
1928 | else | 1930 | else |
1929 | ret = 0; | 1931 | ret = 0; |