mirror of
https://git.openldap.org/openldap/openldap.git
synced 2026-01-02 21:19:53 -05:00
free controls, if needed (ITS#6629)
This commit is contained in:
parent
8be2af29bb
commit
938778ffd9
1 changed files with 16 additions and 0 deletions
|
|
@ -1356,6 +1356,14 @@ error_return:;
|
|||
rs->sr_flags &= ~REP_ENTRY_MUSTBEFREED;
|
||||
}
|
||||
|
||||
if ( rs->sr_flags & REP_CTRLS_MUSTBEFREED ) {
|
||||
rs->sr_flags ^= REP_CTRLS_MUSTBEFREED; /* paranoia */
|
||||
if ( rs->sr_ctrls ) {
|
||||
slap_free_ctrls( op, rs->sr_ctrls );
|
||||
rs->sr_ctrls = NULL;
|
||||
}
|
||||
}
|
||||
|
||||
return( rc );
|
||||
}
|
||||
|
||||
|
|
@ -1510,6 +1518,14 @@ rel:
|
|||
(void)slap_cleanup_play( op, rs );
|
||||
}
|
||||
|
||||
if ( rs->sr_flags & REP_CTRLS_MUSTBEFREED ) {
|
||||
rs->sr_flags ^= REP_CTRLS_MUSTBEFREED; /* paranoia */
|
||||
if ( rs->sr_ctrls ) {
|
||||
slap_free_ctrls( op, rs->sr_ctrls );
|
||||
rs->sr_ctrls = NULL;
|
||||
}
|
||||
}
|
||||
|
||||
return rc;
|
||||
}
|
||||
|
||||
|
|
|
|||
Loading…
Reference in a new issue