This is the mail archive of the cygwin-patches mailing list for the Cygwin project.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]
Other format: [Raw text]

Re: [Patch] Avoid duplicate names in /proc/registry (which may crash find)


Hi Christian,

On Dec  5 23:23, Christian Franke wrote:
> Corinna Vinschen wrote:
>> Maybe ".val" is already a good suffix?
>
> I would prefer "%val" to avoid any extra encoding for names using ".val". 
> The "%" is already used as an escape char, so "%val" in a name would appear 
> as "%25val"

Very good idea!

> With the attached patch, a duplicate name "foo" is handled as follows:
>
> - readdir() returns the key as "foo" and the value as "foo%val".
> - If the name is "foo%val", stat() and open() consider only the value 
> "foo".
>
> This keeps the names 'as is' if possible and allows access to the (very 
> few) entries with duplicate names. The "%val" is at least somewhat 
> self-explanatory.

Cool.  Can you please send a ChangeLog entry as well?


Thanks,
Corinna

-- 
Corinna Vinschen                  Please, send mails regarding Cygwin to
Cygwin Project Co-Leader          cygwin AT cygwin DOT com
Red Hat


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]