summaryrefslogtreecommitdiffstats
path: root/install/tools/ipa-csreplica-manage
diff options
context:
space:
mode:
authorPetr Viktorin <pviktori@redhat.com>2013-01-21 08:39:09 -0500
committerMartin Kosek <mkosek@redhat.com>2013-03-01 16:59:45 +0100
commit4779865ea30dba0b5f0594cdc4633b0cc93bf36a (patch)
tree17708b9facca822d26570de65cd691e12bf3eeff /install/tools/ipa-csreplica-manage
parentf5c404c65d81d9a28f171fabe7c5749d6c37f102 (diff)
downloadfreeipa-4779865ea30dba0b5f0594cdc4633b0cc93bf36a.tar.gz
freeipa-4779865ea30dba0b5f0594cdc4633b0cc93bf36a.tar.xz
freeipa-4779865ea30dba0b5f0594cdc4633b0cc93bf36a.zip
Replace getList by a get_entries method
The find_entries method is cumbersome to use: it requires keyword arguments for simple uses, and callers are tempted to ignore the 'truncated' flag it returns. Introduce a simpler method, get_entries, that returns the found list directly, and raises an errors if the list is truncated. Replace the getList method by get_entries. Part of the work for: https://fedorahosted.org/freeipa/ticket/2660
Diffstat (limited to 'install/tools/ipa-csreplica-manage')
-rwxr-xr-xinstall/tools/ipa-csreplica-manage2
1 files changed, 1 insertions, 1 deletions
diff --git a/install/tools/ipa-csreplica-manage b/install/tools/ipa-csreplica-manage
index 997bbc4e..5cab8b86 100755
--- a/install/tools/ipa-csreplica-manage
+++ b/install/tools/ipa-csreplica-manage
@@ -211,7 +211,7 @@ def list_replicas(realm, host, replica, dirman_passwd, verbose):
conn.do_simple_bind(bindpw=dirman_passwd)
dn = DN(('cn', 'masters'), ('cn', 'ipa'), ('cn', 'etc'), ipautil.realm_to_suffix(realm))
- entries = conn.getList(dn, ldap.SCOPE_ONELEVEL)
+ entries = conn.get_entries(dn, ldap.SCOPE_ONELEVEL)
for ent in entries:
try: