mirror of
https://git.openldap.org/openldap/openldap.git
synced 2025-01-18 11:05:48 +08:00
quick fix for vc: allow custom controls tag
This commit is contained in:
parent
180ad95b16
commit
1a56a1934a
@ -690,10 +690,21 @@ int slap_parse_ctrl(
|
||||
return rc;
|
||||
}
|
||||
|
||||
int get_ctrls(
|
||||
int
|
||||
get_ctrls(
|
||||
Operation *op,
|
||||
SlapReply *rs,
|
||||
int sendres )
|
||||
{
|
||||
return get_ctrls2( op, rs, sendres, LDAP_TAG_CONTROLS );
|
||||
}
|
||||
|
||||
int
|
||||
get_ctrls2(
|
||||
Operation *op,
|
||||
SlapReply *rs,
|
||||
int sendres,
|
||||
ber_tag_t ctag )
|
||||
{
|
||||
int nctrls = 0;
|
||||
ber_tag_t tag;
|
||||
@ -719,7 +730,7 @@ int get_ctrls(
|
||||
return rs->sr_err;
|
||||
}
|
||||
|
||||
if(( tag = ber_peek_tag( ber, &len )) != LDAP_TAG_CONTROLS ) {
|
||||
if(( tag = ber_peek_tag( ber, &len )) != ctag ) {
|
||||
if( tag == LBER_ERROR ) {
|
||||
rs->sr_err = SLAPD_DISCONNECT;
|
||||
rs->sr_text = "unexpected data in PDU";
|
||||
|
@ -650,6 +650,11 @@ LDAP_SLAPD_F (int) get_ctrls LDAP_P((
|
||||
Operation *op,
|
||||
SlapReply *rs,
|
||||
int senderrors ));
|
||||
LDAP_SLAPD_F (int) get_ctrls2 LDAP_P((
|
||||
Operation *op,
|
||||
SlapReply *rs,
|
||||
int senderrors,
|
||||
ber_tag_t ctag ));
|
||||
LDAP_SLAPD_F (int) register_supported_control2 LDAP_P((
|
||||
const char *controloid,
|
||||
slap_mask_t controlmask,
|
||||
|
Loading…
Reference in New Issue
Block a user