From 6200432d85a212b81687eefc53e96129a4388a07 Mon Sep 17 00:00:00 2001 From: Douglas Bagnall Date: Wed, 1 Apr 2015 15:28:26 +1300 Subject: [PATCH] KCC: remove essentially dead code As the removed comment noted, the logic goes: if partial: # ~60 lines up if not partial: ... and we have kept it there for this long because the spec implies it. (As a matter of fact I can't see how this entire `if partial` loop does anything of consequence, given the previous loop didn't exclude the partial case). Signed-off-by: Douglas Bagnall Reviewed-by: Garming Sam Reviewed-by: Andrew Bartlett --- source4/scripting/bin/samba_kcc | 20 -------------------- 1 file changed, 20 deletions(-) diff --git a/source4/scripting/bin/samba_kcc b/source4/scripting/bin/samba_kcc index d4c30d41328..dd21ebf505c 100755 --- a/source4/scripting/bin/samba_kcc +++ b/source4/scripting/bin/samba_kcc @@ -2222,26 +2222,6 @@ class KCC(object): if gc_only and not dc_s.is_gc(): continue - # DC (s) must be in the same site as the local DC - # as this is the intra-site algorithm. This is - # handled by virtue of placing DSAs in per - # site objects (see enclosing for() loop) - - # This criteria is moot (a no-op) for this case - # because we are scanning for (partial = True). The - # MS algorithm statement says partial replica scans - # should adhere to the "same" criteria as full replica - # scans so the criteria doesn't change here...its just - # rendered pointless. - # - # The case that is occurring would be a partial domain - # replica is needed on a local DC global catalog. There - # is no minimum windows behavior for those since GCs - # have always been present. - if ro and not partial and nc_x.nc_type == NCType.domain: - if not dc_s.is_minimum_behavior(dsdb.DS_DOMAIN_FUNCTION_2008): - continue - # If we haven't been told to turn off stale connection # detection and this dsa has a stale connection then # continue -- 2.34.1