From: Alex Lyakas <alex.bolshoy.btrfs@gmail.com>
To: Alexander Block <ablock84@googlemail.com>
Cc: linux-btrfs@vger.kernel.org
Subject: Re: btrfs send/receive: if new inode ino is less than its new directory ino, incorrect path is sent
Date: Mon, 30 Jul 2012 20:35:08 +0300 [thread overview]
Message-ID: <CAHf9xvaccCm3GgHQ_Vj=1gZvecQJDbPhQC-shdODfYPx8QRVwQ@mail.gmail.com> (raw)
In-Reply-To: <CAB9VWqAPvjyQ3EhcZQC59b0qcGr3QFozP60A0q+=FiRv3wxgbg@mail.gmail.com>
Hi,
> I did not apply the patch but instead added a check for dir != tmp_dir
> only. The reason to not check for gen is that I have a rule in my
> mind: I only pass the generation number to functions where I want to
> know the *current* state. is_first_ref is for permanent state, the
> return value never changes while sending. I could however not
> reproduce the problem with test_1.sh, but it should fix it.
I understand. I was not sure about dir_gen either. Since you call this
function to check the permanent state in a particular root, it does
not make sense to compare the generation.
>>
>> btrfs_test_2.sh
>> The last test exposes an interesting issue: when a directory has a
>> deleted reference recorded, this deleted reference is not added to the
>> 'check_dirs' list. As a result, the upper directory (already
>> orphanized) is not rmdir'd.
> You'll find a commit in my repo to fix this. The problem was, that
> moved directories do not get into the delete_refs loop and thus the
> parent of the old location is never added to the check_dirs list.
> I have force pushed to for-alex, if you have time I'd be happy if you
> test again :)
Thanks. It fixes the issue.
...and pls expect another mail from me with a long list of questions I
accumulated:)
Thanks!
Alex.
next prev parent reply other threads:[~2012-07-30 17:35 UTC|newest]
Thread overview: 11+ messages / expand[flat|nested] mbox.gz Atom feed top
2012-07-18 17:45 btrfs send/receive: if new inode ino is less than its new directory ino, incorrect path is sent Alex Lyakas
2012-07-24 20:26 ` Alexander Block
2012-07-26 10:52 ` Alex Lyakas
2012-07-26 14:04 ` Alex Lyakas
2012-07-26 14:07 ` Alexander Block
2012-07-26 21:42 ` Alexander Block
2012-07-27 14:37 ` Alex Lyakas
2012-07-28 9:56 ` Alexander Block
2012-07-29 15:06 ` Alex Lyakas
2012-07-30 17:35 ` Alex Lyakas [this message]
2012-07-30 20:17 ` Alexander Block
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to='CAHf9xvaccCm3GgHQ_Vj=1gZvecQJDbPhQC-shdODfYPx8QRVwQ@mail.gmail.com' \
--to=alex.bolshoy.btrfs@gmail.com \
--cc=ablock84@googlemail.com \
--cc=linux-btrfs@vger.kernel.org \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).