r26649: Only claim to be a PDC if we are a PDC.
authorAndrew Bartlett <abartlet@samba.org>
Thu, 3 Jan 2008 12:00:38 +0000 (06:00 -0600)
committerStefan Metzmacher <metze@samba.org>
Thu, 3 Jan 2008 18:33:35 +0000 (12:33 -0600)
Andrew Bartlett
(This used to be commit fc5746ae95e5a0b751ec19cae1f204c505f4ca27)

source4/cldap_server/netlogon.c

index b79d678e88d58e3c2012dbc098acb8551221ff5d..f77909e8fa1bfdaab72076850fe500b518cf4030 100644 (file)
@@ -162,11 +162,15 @@ static NTSTATUS cldapd_netlogon_fill(struct cldapd_server *cldapd,
        }
 
        server_type      = 
-               NBT_SERVER_PDC | NBT_SERVER_GC | 
+               NBT_SERVER_GC | 
                NBT_SERVER_DS | NBT_SERVER_TIMESERV |
                NBT_SERVER_CLOSEST | NBT_SERVER_WRITABLE | 
                NBT_SERVER_GOOD_TIMESERV;
 
+       if (samdb_is_pdc(cldapd->samctx)) {
+               server_type |= NBT_SERVER_PDC;
+       }
+
        if (str_list_check(services, "ldap")) {
                server_type |= NBT_SERVER_LDAP;
        }