mirror of
https://git.openldap.org/openldap/openldap.git
synced 2025-12-27 01:59:38 -05:00
Call normalizer directly, not rdnNormalize.
This commit is contained in:
parent
c82ae524b9
commit
ebb23234ca
1 changed files with 12 additions and 5 deletions
|
|
@ -654,6 +654,8 @@ static Entry *accesslog_entry( Operation *op, int logop ) {
|
|||
log_info *li = on->on_bi.bi_private;
|
||||
|
||||
char rdnbuf[STRLENOF(RDNEQ)+LDAP_LUTIL_GENTIME_BUFSIZE+8];
|
||||
char nrdnbuf[STRLENOF(RDNEQ)+LDAP_LUTIL_GENTIME_BUFSIZE+8];
|
||||
|
||||
struct berval rdn, nrdn, timestamp, ntimestamp, bv;
|
||||
slap_verbmasks *lo = logops+logop+EN_OFFSET;
|
||||
|
||||
|
|
@ -661,6 +663,8 @@ static Entry *accesslog_entry( Operation *op, int logop ) {
|
|||
|
||||
strcpy( rdnbuf, RDNEQ );
|
||||
rdn.bv_val = rdnbuf;
|
||||
strcpy( nrdnbuf, RDNEQ );
|
||||
nrdn.bv_val = nrdnbuf;
|
||||
|
||||
timestamp.bv_val = rdnbuf+STRLENOF(RDNEQ);
|
||||
timestamp.bv_len = sizeof(rdnbuf) - STRLENOF(RDNEQ);
|
||||
|
|
@ -669,7 +673,13 @@ static Entry *accesslog_entry( Operation *op, int logop ) {
|
|||
timestamp.bv_len += 7;
|
||||
|
||||
rdn.bv_len = STRLENOF(RDNEQ)+timestamp.bv_len;
|
||||
rdnNormalize( 0, NULL, NULL, &rdn, &nrdn, op->o_tmpmemctx );
|
||||
ad_reqStart->ad_type->sat_equality->smr_normalize(
|
||||
SLAP_MR_VALUE_OF_ASSERTION_SYNTAX, ad_reqStart->ad_type->sat_syntax,
|
||||
ad_reqStart->ad_type->sat_equality, ×tamp, &ntimestamp,
|
||||
op->o_tmpmemctx );
|
||||
|
||||
strcpy( nrdn.bv_val + STRLENOF(RDNEQ), ntimestamp.bv_val );
|
||||
nrdn.bv_len += ntimestamp.bv_len;
|
||||
build_new_dn( &e->e_name, li->li_db->be_suffix, &rdn, NULL );
|
||||
build_new_dn( &e->e_nname, li->li_db->be_nsuffix, &nrdn, NULL );
|
||||
|
||||
|
|
@ -677,11 +687,8 @@ static Entry *accesslog_entry( Operation *op, int logop ) {
|
|||
&log_ocs[logop]->soc_cname, NULL );
|
||||
attr_merge_one( e, slap_schema.si_ad_structuralObjectClass,
|
||||
&log_ocs[logop]->soc_cname, NULL );
|
||||
|
||||
ntimestamp.bv_val = nrdn.bv_val + STRLENOF(RDNEQ);
|
||||
ntimestamp.bv_len = nrdn.bv_len - STRLENOF(RDNEQ);
|
||||
attr_merge_one( e, ad_reqStart, ×tamp, &ntimestamp );
|
||||
op->o_tmpfree( nrdn.bv_val, op->o_tmpmemctx );
|
||||
op->o_tmpfree( ntimestamp.bv_val, op->o_tmpmemctx );
|
||||
|
||||
/* Exops have OID appended */
|
||||
if ( logop == LOG_EN_EXTENDED ) {
|
||||
|
|
|
|||
Loading…
Reference in a new issue