- int objnotfound = 0, objlocked = 0;
- int v_nomatch = 0, v_matchlock = 0, v_matchnolock = 0;
-
- /* modptr points to the beginning of the object store
- * created at the Pariticipant */
- pthread_mutex_lock(&mainobjstore_mutex);
- if ((modptr = objstrAlloc(mainobjstore, localtdata->tdata->buffer->f.sum_bytes)) == NULL) {
- printf("objstrAlloc error for modified objects %s, %d\n", __FILE__, __LINE__);
- pthread_mutex_unlock(&mainobjstore_mutex);
- pthread_exit(NULL);
- }
- pthread_mutex_unlock(&mainobjstore_mutex);
- /* Write modified objects into the mainobject store */
- for(i = 0; i< localtdata->tdata->buffer->f.nummod; i++) {
- headeraddr = chashSearch(localtdata->tdata->rec->lookupTable, localtdata->tdata->buffer->oidmod[i]);
- GETSIZE(size,headeraddr);
- size+=sizeof(objheader_t);
- memcpy((char *)modptr+offset, headeraddr, size);
- offset += size;
- }
- /* Write new objects into the mainobject store */
- for(i = 0; i< localtdata->tdata->buffer->f.numcreated; i++) {
- headeraddr = chashSearch(localtdata->tdata->rec->lookupTable, localtdata->tdata->buffer->oidcreated[i]);
- GETSIZE(size, headeraddr);
- size+=sizeof(objheader_t);
- memcpy((char *)modptr+offset, headeraddr, size);
- offset += size;
- }
-
- ptr = modptr;
- offset = 0; //Reset