s3:winbind: For internal domains it is pointless to connect to a DC
authorVolker Lendecke <vl@samba.org>
Sat, 22 Aug 2009 15:13:09 +0000 (17:13 +0200)
committerVolker Lendecke <vl@samba.org>
Sun, 23 Aug 2009 08:19:32 +0000 (10:19 +0200)
source3/winbindd/winbindd_cm.c
source3/winbindd/winbindd_util.c

index 460c7738b39a5b25149a9c3e56716366a35533f9..44924a63035b6fb752ecd1b54245686a6c3a8476 100644 (file)
@@ -485,6 +485,12 @@ void set_domain_online_request(struct winbindd_domain *domain)
                return;
        }
 
+       if (domain->internal) {
+               DEBUG(10, ("set_domain_online_request: Internal domains are "
+                          "always online\n"));
+               return;
+       }
+
        /* We've been told it's safe to go online and
           try and connect to a DC. But I don't believe it
           because network manager seems to lie.
index 993ef54f5d0ed4f76e87e253e4ff25ca11d44d3f..9f853be32a2ea740899207b5fed78f10557724ab 100644 (file)
@@ -569,7 +569,11 @@ enum winbindd_result winbindd_dual_init_connection(struct winbindd_domain *domai
                fstrcpy(domain->dcname, state->request->data.init_conn.dcname);
        }
 
-       init_dc_connection(domain);
+       if (domain->internal) {
+               domain->initialized = true;
+       } else {
+               init_dc_connection(domain);
+       }
 
        if (!domain->initialized) {
                /* If we return error here we can't do any cached authentication,