summaryrefslogtreecommitdiffstats
path: root/source/nsswitch
diff options
context:
space:
mode:
authorTim Potter <tpot@samba.org>2001-06-20 01:52:40 +0000
committerTim Potter <tpot@samba.org>2001-06-20 01:52:40 +0000
commit8e982941d82b813197f2a9720149e60f629b5b20 (patch)
tree8f4ec753fde9b0f95abc7dcc8f3eee2817bedcb5 /source/nsswitch
parent0fe11c329f7b379299be65795031e4f1b14e0bec (diff)
downloadsamba-8e982941d82b813197f2a9720149e60f629b5b20.tar.gz
samba-8e982941d82b813197f2a9720149e60f629b5b20.tar.xz
samba-8e982941d82b813197f2a9720149e60f629b5b20.zip
Merge from appliance branch:
Don't call find_domain_from_name() from winbindd_kill_connections() as you get stuck in an infinite loop!
Diffstat (limited to 'source/nsswitch')
-rw-r--r--source/nsswitch/winbindd_util.c10
1 files changed, 8 insertions, 2 deletions
diff --git a/source/nsswitch/winbindd_util.c b/source/nsswitch/winbindd_util.c
index 4814fbcfdae..4c7071d0633 100644
--- a/source/nsswitch/winbindd_util.c
+++ b/source/nsswitch/winbindd_util.c
@@ -224,11 +224,17 @@ BOOL domain_handles_open(struct winbindd_domain *domain)
void winbindd_kill_connections(struct winbindd_domain *domain)
{
BOOL is_server = False;
- struct winbindd_domain *server_domain;
+ struct winbindd_domain *server_domain = NULL, *tmp;
/* Find pointer to domain of pdc */
- server_domain = find_domain_from_name(lp_workgroup());
+ for (tmp = domain_list; tmp != NULL; tmp = tmp->next) {
+ if (strequal(domain->name, tmp->name)) {
+ server_domain = tmp;
+ break;
+ }
+ }
+
if (!server_domain) return;
/* If NULL passed, use pdc */