summaryrefslogtreecommitdiff
path: root/python
diff options
context:
space:
mode:
authorDouglas Bagnall <douglas.bagnall@catalyst.net.nz>2015-06-25 16:38:29 +1200
committerAndrew Bartlett <abartlet@samba.org>2015-10-29 05:08:15 +0100
commiteec0d119ac755b72f8e881728608a849ad12b66b (patch)
treece0256dcfa346b38ba0ef2f296f9d6a97e91a4f0 /python
parent5bbcbe380b8b5cb7a9f479e585f46040f2d99ad5 (diff)
downloadsamba-eec0d119ac755b72f8e881728608a849ad12b66b.tar.gz
KCC: simplify get_dsa_for_implied_replica(), using IP invariant
We only do IP transports. Therfore the long list of alternatives... (not n_rep.is_domain() or n_rep.is_partial() or cn_conn.transport_dnstr is None or cn_conn.transport_dnstr.find("CN=IP") == 0) that ends with the equivalant of "is this IP?" always evaluates to True. If we leave it there it will confuse people for ever. Signed-off-by: Douglas Bagnall <douglas.bagnall@catalyst.net.nz> Reviewed-by: Garming Sam <garming@catalyst.net.nz> Reviewed-by: Andrew Bartlett <abartlet@samba.org>
Diffstat (limited to 'python')
-rw-r--r--python/samba/kcc/__init__.py8
1 files changed, 1 insertions, 7 deletions
diff --git a/python/samba/kcc/__init__.py b/python/samba/kcc/__init__.py
index a3c31fb672d..039d54a5f60 100644
--- a/python/samba/kcc/__init__.py
+++ b/python/samba/kcc/__init__.py
@@ -845,13 +845,7 @@ class KCC(object):
# replica, cn!transportType has no value, or
# cn!transportType has an RDN of CN=IP.
#
- implied = (not s_rep.is_ro() or n_rep.is_partial()) and \
- (not n_rep.is_domain() or
- n_rep.is_partial() or
- cn_conn.transport_dnstr is None or
- cn_conn.transport_dnstr.find("CN=IP") == 0)
-
- if implied:
+ if not s_rep.is_ro() or n_rep.is_partial():
return s_dsa
return None