summaryrefslogtreecommitdiffstats
path: root/ipapython/ipaldap.py
diff options
context:
space:
mode:
Diffstat (limited to 'ipapython/ipaldap.py')
-rw-r--r--ipapython/ipaldap.py5
1 files changed, 3 insertions, 2 deletions
diff --git a/ipapython/ipaldap.py b/ipapython/ipaldap.py
index 38c6aad04..7e5bc04fe 100644
--- a/ipapython/ipaldap.py
+++ b/ipapython/ipaldap.py
@@ -1314,8 +1314,9 @@ class LDAPClient(object):
# pass arguments to python-ldap
with self.error_handler():
- filter = self.encode(filter)
- attrs_list = self.encode(attrs_list)
+ if six.PY2:
+ filter = self.encode(filter)
+ attrs_list = self.encode(attrs_list)
while True:
if paged_search: