diff options
Diffstat (limited to 'source3/nsswitch')
-rw-r--r-- | source3/nsswitch/winbindd.c | 3 | ||||
-rw-r--r-- | source3/nsswitch/winbindd_dual.c | 3 | ||||
-rw-r--r-- | source3/nsswitch/winbindd_util.c | 21 |
3 files changed, 4 insertions, 23 deletions
diff --git a/source3/nsswitch/winbindd.c b/source3/nsswitch/winbindd.c index df8f821c8b..8d5a7042c6 100644 --- a/source3/nsswitch/winbindd.c +++ b/source3/nsswitch/winbindd.c @@ -1063,7 +1063,8 @@ int main(int argc, char **argv) init_idmap_child(); - winbindd_flush_nscd_cache(); + smb_nscd_flush_user_cache(); + smb_nscd_flush_group_cache(); /* Loop waiting for requests */ diff --git a/source3/nsswitch/winbindd_dual.c b/source3/nsswitch/winbindd_dual.c index 128c468dd3..1a3de3f1e5 100644 --- a/source3/nsswitch/winbindd_dual.c +++ b/source3/nsswitch/winbindd_dual.c @@ -606,7 +606,8 @@ static void child_msg_online(int msg_type, struct process_id src, void *buf, siz /* Set our global state as online. */ set_global_winbindd_state_online(); - winbindd_flush_nscd_cache(); + smb_nscd_flush_user_cache(); + smb_nscd_flush_group_cache(); /* Try and mark everything online - delete any negative cache entries to force a reconnect now. */ diff --git a/source3/nsswitch/winbindd_util.c b/source3/nsswitch/winbindd_util.c index a99115690d..4d99b0fbe6 100644 --- a/source3/nsswitch/winbindd_util.c +++ b/source3/nsswitch/winbindd_util.c @@ -1218,27 +1218,6 @@ BOOL winbindd_upgrade_idmap(void) return idmap_convert(idmap_name); } -void winbindd_flush_nscd_cache(void) -{ -#ifdef HAVE_NSCD_FLUSH_CACHE - - /* Flush nscd caches to get accurate new information */ - int ret = nscd_flush_cache("passwd"); - if (ret) { - DEBUG(5,("failed to flush nscd cache for 'passwd' service: %s\n", - strerror(errno))); - } - - ret = nscd_flush_cache("group"); - if (ret) { - DEBUG(5,("failed to flush nscd cache for 'group' service: %s\n", - strerror(errno))); - } -#else - return; -#endif -} - NTSTATUS lookup_usergroups_cached(struct winbindd_domain *domain, TALLOC_CTX *mem_ctx, const DOM_SID *user_sid, |