mirror of
https://git.openldap.org/openldap/openldap.git
synced 2025-12-24 00:29:35 -05:00
Fix extensible filters
This commit is contained in:
parent
490ac259f4
commit
ccc4d0d5ae
1 changed files with 9 additions and 4 deletions
|
|
@ -591,18 +591,23 @@ put_simple_filter(
|
|||
if( rc != -1 && *str != '\0' ) {
|
||||
rc = ber_printf( ber, "ts", LDAP_FILTER_EXT_TYPE, str );
|
||||
}
|
||||
|
||||
if( rc != -1 ) {
|
||||
ber_slen_t len = ldap_pvt_filter_value_unescape( value );
|
||||
|
||||
if( len >= 0 ) {
|
||||
rc = ber_printf( ber, /*"{"*/ "totbN}",
|
||||
LDAP_FILTER_EXT_VALUE, value, len,
|
||||
LDAP_FILTER_EXT_DNATTRS, dn != NULL);
|
||||
rc = ber_printf( ber, "to",
|
||||
LDAP_FILTER_EXT_VALUE, value, len );
|
||||
} else {
|
||||
rc = -1;
|
||||
}
|
||||
}
|
||||
if( rc != -1 && dn ) {
|
||||
rc = ber_printf( ber, "tb",
|
||||
LDAP_FILTER_EXT_DNATTRS, (ber_int_t) 1 );
|
||||
}
|
||||
if( rc != -1 ) {
|
||||
rc = ber_printf( ber, /*"{"*/ "N}" );
|
||||
}
|
||||
}
|
||||
goto done;
|
||||
|
||||
|
|
|
|||
Loading…
Reference in a new issue