[PATCH v2 1/2] posix: Add compat glob symbol to not follow dangling symbols
Adhemerval Zanella
adhemerval.zanella@linaro.org
Tue Sep 19 12:12:00 GMT 2017
On 19/09/2017 08:14, Szabolcs Nagy wrote:
> On 18/09/17 15:42, Adhemerval Zanella wrote:
>> Changes from previous version:
>>
>> * Fix alpha oldglob definition by making it also not follow dangling
>> symlinks.
>>
>> * Add powerpc64le abilist entries.
>>
>> * Increase _GNU_GLOB_INTERFACE_VERSION to 2 to advertive a new internal
>> glob semantic.
>>
>> ---
>>
>> This patch follows commit 5554304f0 (posix: Allow glob to match dangling
>> symlinks [BZ #866]) by adding a compat symbol that follow previous
>> semantic of not following dangling symlinks and thus avoiding call
>> gl_lstat with GLOB_ALTDIRFUNC.
>>
>> It avoids failure with old binaries that not set the alternate function
>> pointer for lstat (GNUmake for instance). The following scenario, for
>> instance, fails with current GNUmake because glibc will access unitialized
>> memory when calling gl_lstat:
>>
>
> i still think the original change should be reverted
> until there is a released version of make with the fix.
>
> build scripts will use a released version of make
> and the breakage will go unnoticed until make is
> run on the newly built system.
>
With this patch this scenario should not happen, either GNUmake will be
built against _GNU_GLOB_INTERFACE_VERSION equal to 1 and use the compat
symbol or use its own glob version for newer builds.
When GNUmake fixes its GLOB_ALTDIRFUNC usage it also should update the
config script to check for _GNU_GLOB_INTERFACE_VERSION to 1 and/or 2.
More information about the Libc-alpha
mailing list