summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorLukas Slebodnik <lslebodn@redhat.com>2013-11-13 08:32:23 +0100
committerJakub Hrozek <jhrozek@redhat.com>2013-11-14 19:43:57 +0100
commit6f9b5e7ebfe037795afbae0c5b25a6337c94c4c6 (patch)
treebe52a820f9506f853373ba1a6e1171b560e4c807
parentcc6c85c5951ac5dd3c33266730a34701898cecf7 (diff)
downloadsssd-6f9b5e7ebfe037795afbae0c5b25a6337c94c4c6.tar.gz
sssd-6f9b5e7ebfe037795afbae0c5b25a6337c94c4c6.tar.xz
sssd-6f9b5e7ebfe037795afbae0c5b25a6337c94c4c6.zip
LDAP: Prevent from using uninitialized sdap_options
ldap_get_options can fail in time of ldap back end initialisation and then sssd try to release uninitialised sdap_options. Resolves: https://fedorahosted.org/sssd/ticket/2147
-rw-r--r--src/providers/ldap/ldap_init.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/src/providers/ldap/ldap_init.c b/src/providers/ldap/ldap_init.c
index 17874b132..15615b289 100644
--- a/src/providers/ldap/ldap_init.c
+++ b/src/providers/ldap/ldap_init.c
@@ -94,7 +94,7 @@ int sssm_ldap_id_init(struct be_ctx *bectx,
const char *dns_service_name;
const char *sasl_mech;
struct sdap_service *sdap_service;
- struct sdap_options *opts;
+ struct sdap_options *opts = NULL;
int ret;
/* If we're already set up, just return that */