From: Howard Chu Date: Tue, 16 May 2006 22:16:13 +0000 (+0000) Subject: ITS#4466 fix typo, uninit'd var X-Git-Tag: OPENLDAP_REL_ENG_2_4_3ALPHA~9^2~252 X-Git-Url: https://git.sur5r.net/?a=commitdiff_plain;h=1135d19f16340fa81ef8abb44c830c65c8dec6d3;p=openldap ITS#4466 fix typo, uninit'd var --- diff --git a/servers/slapd/slapi/slapi_pblock.c b/servers/slapd/slapi/slapi_pblock.c index 7ced845876..ea6d4edcb2 100644 --- a/servers/slapd/slapi/slapi_pblock.c +++ b/servers/slapd/slapi/slapi_pblock.c @@ -624,7 +624,7 @@ pblock_get( Slapi_PBlock *pb, int param, void **value ) break; case SLAPI_MODIFY_MODS: { LDAPMod **mods = NULL; - Modifications *ml; + Modifications *ml = NULL; pblock_get_default( pb, param, (void **)&mods ); if ( mods == NULL && pb->pb_intop == 0 ) { @@ -635,12 +635,14 @@ pblock_get( Slapi_PBlock *pb, int param, void **value ) case LDAP_REQ_MODRDN: ml = pb->pb_op->orr_modlist; break; - defaulat: + default: rc = PBLOCK_ERROR; break; } - mods = slapi_int_modifications2ldapmods( ml ); - pblock_set_default( pb, param, (void *)mods ); + if ( rc != PBLOCK_ERROR ) { + mods = slapi_int_modifications2ldapmods( ml ); + pblock_set_default( pb, param, (void *)mods ); + } } *((LDAPMod ***)value) = mods; break;