summaryrefslogtreecommitdiffstats
path: root/src/providers/ad
diff options
context:
space:
mode:
authorMichal Zidek <mzidek@redhat.com>2012-08-13 16:37:13 +0200
committerJakub Hrozek <jhrozek@redhat.com>2012-08-15 13:51:22 +0200
commit9ab243b369ba317cc964080786dbcdebaf23d6be (patch)
tree7a08b9d00a11e2946a00bcee9b8fc093ee10b19f /src/providers/ad
parent4f76afc76610a26da85438e5657a6cb5e83c787a (diff)
downloadsssd-9ab243b369ba317cc964080786dbcdebaf23d6be.tar.gz
sssd-9ab243b369ba317cc964080786dbcdebaf23d6be.tar.xz
sssd-9ab243b369ba317cc964080786dbcdebaf23d6be.zip
Duplicate detection in fail over did not work.
https://fedorahosted.org/sssd/ticket/1472
Diffstat (limited to 'src/providers/ad')
-rw-r--r--src/providers/ad/ad_common.c7
1 files changed, 6 insertions, 1 deletions
diff --git a/src/providers/ad/ad_common.c b/src/providers/ad/ad_common.c
index 800ef131f..90cfe412f 100644
--- a/src/providers/ad/ad_common.c
+++ b/src/providers/ad/ad_common.c
@@ -207,6 +207,11 @@ done:
return ret;
}
+static int ad_user_data_cmp(void *ud1, void *ud2)
+{
+ return strcasecmp((char*) ud1, (char*) ud2);
+}
+
errno_t
ad_failover_init(TALLOC_CTX *mem_ctx, struct be_ctx *bectx,
const char *primary_servers,
@@ -240,7 +245,7 @@ ad_failover_init(TALLOC_CTX *mem_ctx, struct be_ctx *bectx,
goto done;
}
- ret = be_fo_add_service(bectx, AD_SERVICE_NAME);
+ ret = be_fo_add_service(bectx, AD_SERVICE_NAME, ad_user_data_cmp);
if (ret != EOK) {
DEBUG(SSSDBG_CRIT_FAILURE, ("Failed to create failover service!\n"));
goto done;