mirror of
https://salsa.debian.org/freeipa-team/freeipa.git
synced 2024-12-25 16:31:08 -06:00
Don't check for schema uniqueness when comparing in ldapupdate.
This is needed on F-17+, otherwise things blow up when we try to see if we've added new schema. Introspection is required to see if the argument check_uniqueness is available. https://fedorahosted.org/freeipa/ticket/2383
This commit is contained in:
parent
ecf544ea0b
commit
7aeae93c34
@ -43,6 +43,7 @@ import os
|
||||
import pwd
|
||||
import fnmatch
|
||||
import csv
|
||||
import inspect
|
||||
from ipaserver.install.plugins import PRE_UPDATE, POST_UPDATE
|
||||
from ipaserver.install.plugins import FIRST, MIDDLE, LAST
|
||||
|
||||
@ -586,7 +587,11 @@ class LDAPUpdate:
|
||||
return True if the schema has changed
|
||||
return False if it has not
|
||||
"""
|
||||
s = ldap.schema.SubSchema(s)
|
||||
signature = inspect.getargspec(ldap.schema.SubSchema.__init__)
|
||||
if 'check_uniqueness' in signature.args:
|
||||
s = ldap.schema.SubSchema(s, check_uniqueness=0)
|
||||
else:
|
||||
s = ldap.schema.SubSchema(s)
|
||||
s = s.ldap_entry()
|
||||
|
||||
# Get a fresh copy and convert into a SubSchema
|
||||
|
Loading…
Reference in New Issue
Block a user