This is the mail archive of the libc-alpha@sourceware.org mailing list for the glibc 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] Fix nss/nss_test1.c compile with latest GCC


On Fri, Jul 21, 2017 at 9:54 AM, Steve Ellcey <sellcey@cavium.com> wrote:
> On Wed, 2017-07-19 at 19:13 -0400, DJ Delorie wrote:
>> Steve Ellcey <sellcey@cavium.com> writes:
>> >
>> > I think this is due to new error checking added to GCC and in this
>> > case I think that GCC is correct in its error.  We should
>> > be using the default_pwd_data in this expression and not pwd_data.
>> Correct, although no existing tests actually use that data, so the
>> bug
>> (and the fix) do not affect test results.
>>
>> >
>> > This patch fixes the proglem, OK for checkin?
>> I was going to check in the same patch... but my rawhide gcc didn't
>> give
>> a warning so I haddn't yet confirmed it.
>>
>> So LGTM :-)
>>
>> Thanks!
>
> Since there haven't seen any objections to this I am going to go ahead
> and check it in.
>

On Fedora 26, this caused:

[hjl@gnu-tools-1 build-x86_64-linux]$ nss/tst-nss-test5
[1] passwd entry 30.name30 had uid 300
[1] passwd entry 30.name30 had pw_name "name300" (expected "name30")
    passwd 300.name300 (*) : 100, *, *, *

    passwd 30.name30 (*) : 100, *, *, *

[2] passwd pw_name for 200.name200 was (null)
    passwd 200.(null) (*) : 100, *, *, *

    passwd 200.name200 (*) : 100, *, *, *

[3] passwd pw_name for 60.(null) was name60
    passwd 60.name60 (*) : 100, *, *, *

    passwd 60.(null) (*) : 100, *, *, *

[4] passwd entry 20000.name20000 had gid 200 (expected 100)
    passwd 20000.name20000 (*) : 200, *, *, *

    passwd 20000.name20000 (*) : 100, *, *, *

[5] passwd entry 2.name2 had gid 2 (expected 100)
[5] passwd entry 2.name2 had pw_passwd "x" (expected "*")
[5] passwd entry 2.name2 had pw_gecos "y" (expected "*")
[5] passwd entry 2.name2 had pw_dir "z" (expected "*")
    passwd 2.name2 (x) : 2, y, z, *

    passwd 2.name2 (*) : 100, *, *, *

FAIL: [?] passwd entry 30.name30 unexpected
FAIL: Found 10 errors, expected 9
[hjl@gnu-tools-1 build-x86_64-linux]$



-- 
H.J.


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