diff options
author | Noriko Hosoi <nhosoi@redhat.com> | 2010-10-22 05:51:34 -0700 |
---|---|---|
committer | Noriko Hosoi <nhosoi@redhat.com> | 2010-10-22 05:51:34 -0700 |
commit | 13ccbd40a2be34daf5a34cd99e5ed0b325744d00 (patch) | |
tree | 52386af11487c606967f803572db1b4fa99eb6fe /ldap | |
parent | 5cd9fc9826fd88b8672129e41523065c0b692c3b (diff) | |
download | ds-master.tar.gz ds-master.tar.xz ds-master.zip |
https://bugzilla.redhat.com/show_bug.cgi?id=644608
Description:
Previous cherry-pick commit 5cd9fc9826fd88b8672129e41523065c0b692c3b
failed the merge for setting a special dup compare callback
ai_dup_cmp_fn when it is set.
Diffstat (limited to 'ldap')
-rw-r--r-- | ldap/servers/slapd/back-ldbm/dblayer.c | 7 |
1 files changed, 6 insertions, 1 deletions
diff --git a/ldap/servers/slapd/back-ldbm/dblayer.c b/ldap/servers/slapd/back-ldbm/dblayer.c index a052d00b..9a9f6af0 100644 --- a/ldap/servers/slapd/back-ldbm/dblayer.c +++ b/ldap/servers/slapd/back-ldbm/dblayer.c @@ -2812,7 +2812,12 @@ _dblayer_set_db_callbacks(dblayer_private *priv, DB *dbp, struct attrinfo *ai) if (rc) return rc; - rc = dbp->set_dup_compare( dbp, idl_new_compare_dups); + if (ai->ai_dup_cmp_fn) { + /* If set, use the special dup compare callback */ + rc = dbp->set_dup_compare(dbp, ai->ai_dup_cmp_fn); + } else { + rc = dbp->set_dup_compare(dbp, idl_new_compare_dups); + } if (rc) return rc; } |