Diff for /servers/slapd/overlays/syncprov.c between versions 1.220 and 1.221

version 1.220, 2008/03/13 09:49:32 version 1.221, 2008/03/14 15:49:53
Line 1 Line 1
 /* $OpenLDAP: pkg/ldap/servers/slapd/overlays/syncprov.c,v 1.219 2008/03/12 21:31:28 ando Exp $ */  /* $OpenLDAP: pkg/ldap/servers/slapd/overlays/syncprov.c,v 1.220 2008/03/13 09:49:32 hyc Exp $ */
 /* syncprov.c - syncrepl provider */  /* syncprov.c - syncrepl provider */
 /* This work is part of OpenLDAP Software <http://www.openldap.org/>.  /* This work is part of OpenLDAP Software <http://www.openldap.org/>.
  *   *
Line 840  static int Line 840  static int
 syncprov_qplay( Operation *op, struct re_s *rtask )  syncprov_qplay( Operation *op, struct re_s *rtask )
 {  {
         syncops *so = rtask->arg;          syncops *so = rtask->arg;
         slap_overinst *on = so->s_op->o_private;          slap_overinst *on = LDAP_SLIST_FIRST(&so->s_op->o_extra)->oe_key;
         syncres *sr;          syncres *sr;
         Entry *e;          Entry *e;
         opcookie opc;          opcookie opc;
Line 933  syncprov_qtask( void *ctx, void *arg ) Line 933  syncprov_qtask( void *ctx, void *arg )
         be = *so->s_op->o_bd;          be = *so->s_op->o_bd;
         be.be_flags |= SLAP_DBFLAG_OVERLAY;          be.be_flags |= SLAP_DBFLAG_OVERLAY;
         op->o_bd = &be;          op->o_bd = &be;
         op->o_private = NULL;          LDAP_SLIST_FIRST(&op->o_extra) = NULL;
         op->o_callback = NULL;          op->o_callback = NULL;
   
         rc = syncprov_qplay( op, rtask );          rc = syncprov_qplay( op, rtask );
Line 1854  syncprov_search_cleanup( Operation *op, Line 1854  syncprov_search_cleanup( Operation *op,
 typedef struct SyncOperationBuffer {  typedef struct SyncOperationBuffer {
         Operation               sob_op;          Operation               sob_op;
         Opheader                sob_hdr;          Opheader                sob_hdr;
           OpExtra                 sob_oe;
         AttributeName   sob_extra;      /* not always present */          AttributeName   sob_extra;      /* not always present */
         /* Further data allocated here */          /* Further data allocated here */
 } SyncOperationBuffer;  } SyncOperationBuffer;
Line 1882  syncprov_detach_op( Operation *op, synco Line 1883  syncprov_detach_op( Operation *op, synco
         sopbuf2 = ch_calloc( 1, size );          sopbuf2 = ch_calloc( 1, size );
         op2 = &sopbuf2->sob_op;          op2 = &sopbuf2->sob_op;
         op2->o_hdr = &sopbuf2->sob_hdr;          op2->o_hdr = &sopbuf2->sob_hdr;
           LDAP_SLIST_FIRST(&op2->o_extra) = &sopbuf2->sob_oe;
   
         /* Copy the fields we care about explicitly, leave the rest alone */          /* Copy the fields we care about explicitly, leave the rest alone */
         *op2->o_hdr = *op->o_hdr;          *op2->o_hdr = *op->o_hdr;
Line 1889  syncprov_detach_op( Operation *op, synco Line 1891  syncprov_detach_op( Operation *op, synco
         op2->o_time = op->o_time;          op2->o_time = op->o_time;
         op2->o_bd = on->on_info->oi_origdb;          op2->o_bd = on->on_info->oi_origdb;
         op2->o_request = op->o_request;          op2->o_request = op->o_request;
         op2->o_private = on;          LDAP_SLIST_FIRST(&op2->o_extra)->oe_key = on;
           LDAP_SLIST_NEXT(LDAP_SLIST_FIRST(&op2->o_extra), oe_next) = NULL;
   
         ptr = (char *) sopbuf2 + offsetof( SyncOperationBuffer, sob_extra );          ptr = (char *) sopbuf2 + offsetof( SyncOperationBuffer, sob_extra );
         if ( i ) {          if ( i ) {

Removed from v.1.220  
changed lines
  Added in v.1.221


______________
© Copyright 1998-2020, OpenLDAP Foundation, info@OpenLDAP.org