summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorLukas Slebodnik <lslebodn@redhat.com>2013-11-13 08:32:23 +0100
committerJakub Hrozek <jhrozek@redhat.com>2013-12-02 17:00:51 +0100
commit5eea6f1e7a43bdd63a1530fb9c68ef292f431f4f (patch)
treefaccdbe50b1aa6bd3c0112e6927c31372c581dbd
parent8285fdca515e103eed41625a444de6fe72c5daa7 (diff)
downloadsssd-5eea6f1e7a43bdd63a1530fb9c68ef292f431f4f.tar.gz
sssd-5eea6f1e7a43bdd63a1530fb9c68ef292f431f4f.tar.xz
sssd-5eea6f1e7a43bdd63a1530fb9c68ef292f431f4f.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 */