bug-coreutils
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

bug#21460: Race condition in tests/tail-2/assert.sh


From: Paul Eggert
Subject: bug#21460: Race condition in tests/tail-2/assert.sh
Date: Fri, 11 Sep 2015 10:18:36 -0700
User-agent: Mozilla/5.0 (X11; Linux x86_64; rv:38.0) Gecko/20100101 Thunderbird/38.2.0

Ludovic Courtès wrote:
I think the problem happens when ‘tail’ opens ‘foo’ right in between of
the two notifications: ‘foo’ is still there, and so ‘tail’ doesn’t
report anything.

Does that make sense?

Yes, though if the link count is indeed zero, I'm surprised that 'tail' can open the file -- that sounds like a bug in the kernel.

If there is such a kernel bug and 'tail' can open a file with a link count of zero, that would explain why 'tail' does not immediately receive an IN_DELETE_SELF notification: after all, the file is open (by 'tail' itself) so it should not be deleted even if it has a link count of zero. If so, it appears that there's another kernel bug later: when 'tail' closes the file's last file descriptor, the file should be deleted and an IN_DELETE_SELF notification should be sent to 'tail'.





reply via email to

[Prev in Thread] Current Thread [Next in Thread]