}
if ( lr->lr_origid == msgid ) {/* child: abandon it */
(void) do_abandon( ld,
- msgid, lr->lr_msgid, sctrls, cctrls );
+ lr->lr_origid, lr->lr_msgid, sctrls, cctrls );
}
}
return LDAP_SUCCESS;
}
+ /* fetch again the request that we are abandoning */
+ if ( lr != NULL ) {
+ for ( lr = ld->ld_requests; lr != NULL; lr = lr->lr_next ) {
+ if ( lr->lr_msgid == msgid ) { /* this message */
+ break;
+ }
+ }
+ }
+
err = 0;
if ( sendabandon ) {
if( ber_sockbuf_ctrl( ld->ld_sb, LBER_SB_OPT_GET_FD, NULL ) == -1 ) {