]> git.sur5r.net Git - openldap/commitdiff
restore op before checking result (and, if necessary, bailing out)
authorPierangelo Masarati <ando@openldap.org>
Mon, 19 Mar 2007 15:50:28 +0000 (15:50 +0000)
committerPierangelo Masarati <ando@openldap.org>
Mon, 19 Mar 2007 15:50:28 +0000 (15:50 +0000)
servers/slapd/back-ldap/bind.c

index 9ea112bf936c4e934e7f28495675cfdfa9844024..8513759bff6d0da6a08704d5258c3461c715c380 100644 (file)
@@ -781,13 +781,13 @@ ldap_back_getconn(
                        op->o_ndn = op->o_req_ndn;
                }
                isproxyauthz = ldap_back_is_proxy_authz( op, rs, sendok, binddn, bindcred );
-               if ( isproxyauthz == -1 ) {
-                       return NULL;
-               }
                if ( op->o_tag == LDAP_REQ_BIND ) {
                        op->o_dn = save_o_dn;
                        op->o_ndn = save_o_ndn;
                }
+               if ( isproxyauthz == -1 ) {
+                       return NULL;
+               }
 
                lc_curr.lc_local_ndn = op->o_ndn;
                /* Explicit binds must not be shared;