Re: [PATCH 0/4] attribute regression fix for maint-1.8.1 and upward

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

 



On Wed, Mar 27, 2013 at 10:57 AM, Junio C Hamano <gitster@xxxxxxxxx> wrote:
> Duy Nguyen <pclouds@xxxxxxxxx> writes:
>
>> How about this? git_check_attr() now takes dtype as an argument
>> and the caller must not add the trailing slash.  This could be
>> split into two patches, one for git_check_attr prototype change,
>> and the other the real meat.
>
> "git check-attr" fundamentally cannot know, but aside from that do
> all the callsites know if the path in question is a directory or
> not?  My impression was that there are some cases you do not
> necessarily know.
>
> "Add slash when you _know_ it is a directory, but otherwise pass the
> path without trailing slash." is easier to understand than "Pass
> 040000 if you know it is a directory, but otherwise pass 100644",
> exactly because "otherwise" in both of these instructions include
> the case where the path in question _is_ a directory (you just do
> not know what it is).
>
> I do not particularly like the "trailing slash on the basename"
> approach, but it feels less bad than passing dtype down.

Fair enough. I'll rebase my changes on top of yours as long term
cleanup. Maybe I can make nwildmatch take patternlen too.
-- 
Duy
--
To unsubscribe from this list: send the line "unsubscribe git" in
the body of a message to majordomo@xxxxxxxxxxxxxxx
More majordomo info at  http://vger.kernel.org/majordomo-info.html




[Index of Archives]     [Linux Kernel Development]     [Gcc Help]     [IETF Annouce]     [DCCP]     [Netdev]     [Networking]     [Security]     [V4L]     [Bugtraq]     [Yosemite]     [MIPS Linux]     [ARM Linux]     [Linux Security]     [Linux RAID]     [Linux SCSI]     [Fedora Users]