From 1fd3c797a822ac121a481f5ba686779d6e620ed8 Mon Sep 17 00:00:00 2001 From: Kurt Zeilenga Date: Mon, 28 Jun 1999 22:22:27 +0000 Subject: [PATCH] Validate outvalue after session param. --- libraries/libldap/options.c | 10 +++++----- 1 file changed, 5 insertions(+), 5 deletions(-) diff --git a/libraries/libldap/options.c b/libraries/libldap/options.c index 748f9c4078..ef19dfda61 100644 --- a/libraries/libldap/options.c +++ b/libraries/libldap/options.c @@ -88,11 +88,6 @@ ldap_get_option( ldap_int_initialize(); } - if(outvalue == NULL) { - /* no place to get to */ - return LDAP_OPT_ERROR; - } - if(ld == NULL) { lo = &ldap_int_global_options; @@ -106,6 +101,11 @@ ldap_get_option( lo = &ld->ld_options; } + if(outvalue == NULL) { + /* no place to get to */ + return LDAP_OPT_ERROR; + } + switch(option) { case LDAP_OPT_API_INFO: { struct ldapapiinfo *info = (struct ldapapiinfo *) outvalue; -- 2.39.5