On 07/07/2011 03:02 PM, Paul Eggert wrote:
> On 07/07/11 10:41, Eric Blake wrote:
>> This gives clients the option to try a non-invasive traversal,
> 
> Thanks for doing that; a couple of minor comments:
> 
>> -            int fd = open (".", O_SEARCH);
>> +            int fd = open (".",
>> +                           O_SEARCH | (ISSET (FTS_NOATIME) ? O_NOATIME : 
>> 0));
> 
> Shouldn't this use diropen rather than open?  Then you don't need
> to worry about checking the flag here.  (This comment applies to
> the existing code, too.)

Possibly.  Jim?

> 
>> +          int parent_fd = openat (cwd_fd, "..", O_SEARCH | O_NOATIME);
> 
> This uses O_NOATIME even when the user hasn't asked for it.

Yeah, because it is in debug-only code.  Debug code shouldn't interfere
with normal operation, whether or not FTS_NOATIME is in effect in normal
operation.

-- 
Eric Blake   [email protected]    +1-801-349-2682
Libvirt virtualization library http://libvirt.org

Attachment: signature.asc
Description: OpenPGP digital signature

Reply via email to