mirror of
https://sourceware.org/git/glibc.git
synced 2024-11-24 10:22:41 +08:00
9b456c5da9
__nss_database_lookup2's extra arguments were left unused in the nsswitch reloading patch set; this broke compat (default config ignored) and shadow files (secondary name ignored) which relies on these fallbacks. This patch adds in the previous behavior by correcting the initialization of the database list to reflect the fallbacks. This means that the nss_database_lookup2 interface no longer needs to be passed the fallback info, so API and callers were adjusted. Since all callers needed to be edited anyway, the calls were changed from __nss_database_lookup2 to the faster __nss_database_get. This was an intended optimization which was deferred during the initial lookup changes to avoid touching so many files. The test case verifies that compat targets work (passwd) and that the default configuration works (group). Tested on x86-64.
46 lines
1.5 KiB
Modula-2
46 lines
1.5 KiB
Modula-2
/* List of all databases defined for the NSS in GNU C Library.
|
|
Copyright (C) 1996-2021 Free Software Foundation, Inc.
|
|
This file is part of the GNU C Library.
|
|
Contributed by Ulrich Drepper <drepper@cygnus.com>, 1996.
|
|
|
|
The GNU C Library is free software; you can redistribute it and/or
|
|
modify it under the terms of the GNU Lesser General Public
|
|
License as published by the Free Software Foundation; either
|
|
version 2.1 of the License, or (at your option) any later version.
|
|
|
|
The GNU C Library is distributed in the hope that it will be useful,
|
|
but WITHOUT ANY WARRANTY; without even the implied warranty of
|
|
MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
|
|
Lesser General Public License for more details.
|
|
|
|
You should have received a copy of the GNU Lesser General Public
|
|
License along with the GNU C Library; if not, see
|
|
<https://www.gnu.org/licenses/>. */
|
|
|
|
/* This list must be kept sorted!!! If any long name is added the
|
|
field size for it must be increases. */
|
|
|
|
DEFINE_DATABASE (aliases)
|
|
DEFINE_DATABASE (ethers)
|
|
DEFINE_DATABASE (group)
|
|
DEFINE_DATABASE (group_compat)
|
|
DEFINE_DATABASE (gshadow)
|
|
DEFINE_DATABASE (hosts)
|
|
DEFINE_DATABASE (initgroups)
|
|
DEFINE_DATABASE (netgroup)
|
|
DEFINE_DATABASE (networks)
|
|
DEFINE_DATABASE (passwd)
|
|
DEFINE_DATABASE (passwd_compat)
|
|
DEFINE_DATABASE (protocols)
|
|
DEFINE_DATABASE (publickey)
|
|
DEFINE_DATABASE (rpc)
|
|
DEFINE_DATABASE (services)
|
|
DEFINE_DATABASE (shadow)
|
|
DEFINE_DATABASE (shadow_compat)
|
|
|
|
/*
|
|
Local Variables:
|
|
mode:C
|
|
End:
|
|
*/
|