ber_free(ber, 1);
return;
}
+ }
+ if (conn->c_is_udp && op->o_protocol == LDAP_VERSION2) {
rc = ber_printf( ber, "{is{t{ess",
msgid, "", tag, err,
matched == NULL ? "" : matched,
rc = ber_printf( ber, "N}N}" );
}
#ifdef LDAP_CONNECTIONLESS
- if( conn->c_is_udp && rc != -1 ) {
+ if( conn->c_is_udp && op->o_protocol == LDAP_VERSION2 && rc != -1 ) {
rc = ber_printf( ber, "N}" );
}
#endif
ber_free(ber, 1);
return;
}
+ }
+ if (conn->c_is_udp && op->o_protocol == LDAP_VERSION2) {
rc = ber_printf( ber, "{is{t{s{",
op->o_msgid, "", LDAP_RES_SEARCH_ENTRY, e->e_dn );
} else
ber_free( ber, 1 );
send_ldap_result( conn, op, LDAP_OTHER,
NULL, "encoding description error", NULL, NULL );
+ attrs_free( aa );
goto error_return;
}
ber_free( ber, 1 );
send_ldap_result( conn, op, LDAP_OTHER,
NULL, "encoding values error", NULL, NULL );
+ attrs_free( aa );
goto error_return;
}
}
ber_free( ber, 1 );
send_ldap_result( conn, op, LDAP_OTHER,
NULL, "encode end error", NULL, NULL );
+ attrs_free( aa );
goto error_return;
}
}
rc = ber_printf( ber, /*{{{*/ "}N}N}" );
#ifdef LDAP_CONNECTIONLESS
- if (conn->c_is_udp && rc != -1)
+ if (conn->c_is_udp && op->o_protocol == LDAP_VERSION2 && rc != -1)
rc = ber_printf( ber, "}" );
#endif
if ( rc == -1 ) {