op->o_pagedresults_state = conn->c_pagedresults_state;
#endif
#ifdef LDAP_CONNECTIONLESS
- op->o_peeraddr = peeraddr;
- if (cdn ) {
- ber_str2bv( cdn, 0, 1, &op->o_dn );
- op->o_protocol = LDAP_VERSION2;
- }
if (conn->c_is_udp) {
int rc;
+ if ( cdn ) {
+ ber_str2bv( cdn, 0, 1, &op->o_dn );
+ op->o_protocol = LDAP_VERSION2;
+ }
op->o_res_ber = ber_alloc_t( LBER_USE_DER );
if (op->o_res_ber == NULL)
return 1;
- rc = ber_write(op->o_res_ber, (char *)&op->o_peeraddr, sizeof(struct sockaddr), 0);
+ rc = ber_write(op->o_res_ber, (char *)&peeraddr, sizeof(struct sockaddr), 0);
if (rc != sizeof(struct sockaddr)) {
#ifdef NEW_LOGGING
LDAP_LOG( CONNECTION, INFO,
}
if (conn->c_protocol == LDAP_VERSION2) {
- rc = ber_printf(op->o_res_ber, "{i{" /*}}*/, op->o_msgid);
+ rc = ber_printf(op->o_res_ber, "{is{" /*}}*/, op->o_msgid, "");
if (rc == -1) {
#ifdef NEW_LOGGING
LDAP_LOG( CONNECTION, INFO,
}
#ifdef LDAP_CONNECTIONLESS
- if (conn->c_is_udp && conn->c_protocol == LDAP_VERSION2) {
+ if (conn->c_is_udp && op->o_protocol == LDAP_VERSION2) {
rc = ber_printf( ber, "t{ess" /*"}}"*/,
tag, err,
matched == NULL ? "" : matched,
ber_init_w_nullc( ber, LBER_USE_DER );
#ifdef LDAP_CONNECTIONLESS
- if (conn->c_is_udp && conn->c_protocol == LDAP_VERSION2) {
- rc = ber_printf(ber, "t{0{" /*}}*/,
+ if (conn->c_is_udp && op->o_protocol == LDAP_VERSION2) {
+ rc = ber_printf(ber, "t{O{" /*}}*/,
LDAP_RES_SEARCH_ENTRY, &e->e_name);
} else
#endif
LDAP_LIST_ENTRY(slap_op) link;
#endif
-#ifdef LDAP_CONNECTIONLESS
- Sockaddr o_peeraddr; /* UDP peer address */
-#endif
AuthorizationInformation o_authz;
BerElement *o_ber; /* ber of the request */