- Timestamp:
- Jun 14, 2013, 12:50:47 PM (11 years ago)
- Location:
- branches/fc19-dev
- Files:
-
- 2 edited
Legend:
- Unmodified
- Added
- Removed
-
branches/fc19-dev
- Property svn:mergeinfo changed
/trunk (added) merged: 2405-2421,2425-2428,2432-2433
- Property svn:mergeinfo changed
-
branches/fc19-dev/server/common/oursrc/nss_nonlocal/nonlocal-passwd.c
r1825 r2434 26 26 27 27 #define _GNU_SOURCE 28 28 29 #include <sys/types.h> 30 #include <dlfcn.h> 31 #include <errno.h> 32 #include <nss.h> 33 #include <pwd.h> 34 #include <stdbool.h> 35 #include <stddef.h> 36 #include <stdlib.h> 37 #include <string.h> 38 #include <syslog.h> 29 39 #include <unistd.h> 30 #include <stdlib.h> 31 #include <stdint.h> 32 #include <string.h> 33 #include <dlfcn.h> 34 #include <stdio.h> 35 #include <syslog.h> 36 #include <errno.h> 37 #include <pwd.h> 38 #include <grp.h> 39 #include <nss.h> 40 40 41 #include "nsswitch-internal.h" 41 42 #include "nonlocal.h" … … 162 163 163 164 165 static bool pwent_initialized = false; 164 166 static service_user *pwent_startp, *pwent_nip; 165 167 static void *pwent_fct_start; … … 186 188 return status; 187 189 188 if ( pwent_fct_start == NULL)190 if (!pwent_initialized) { 189 191 __nss_passwd_nonlocal_lookup(&pwent_startp, pwent_fct_name, 190 192 &pwent_fct_start); 193 __sync_synchronize(); 194 pwent_initialized = true; 195 } 191 196 pwent_nip = pwent_startp; 192 197 pwent_fct.ptr = pwent_fct_start; … … 200 205 const struct walk_nss w = { 201 206 .lookup = &__nss_passwd_nonlocal_lookup, .fct_name = "endpwent", 202 .status = &status 207 .status = &status, .all_values = 1, 203 208 }; 204 209 const __typeof__(&_nss_nonlocal_endpwent) self = NULL;
Note: See TracChangeset
for help on using the changeset viewer.