fix deadlock in check_multiplexer.
This commit is contained in:
parent
e2498b62be
commit
17ac09c652
2 changed files with 2 additions and 5 deletions
|
@ -389,7 +389,6 @@ LogEntry* reserveEntry_LogWriter(struct stasis_log_t* log, size_t sz) {
|
|||
int entryDone_LogWriter(struct stasis_log_t* log, LogEntry* e) {
|
||||
stasis_log_safe_writes_state* sw = log->impl;
|
||||
pthread_mutex_unlock(&sw->write_mutex);
|
||||
// int ret = writeLogEntry_LogWriter(log, e);
|
||||
free(e);
|
||||
return 0;
|
||||
}
|
||||
|
|
|
@ -177,18 +177,16 @@ START_TEST(multiplexTest) {
|
|||
|
||||
array = (lsn_t*)calloc(NUM_INSERTS, sizeof(lsn_t));
|
||||
|
||||
stasis_log_t * log = stasis_log();
|
||||
|
||||
for(i = 0; i < NUM_INSERTS; i++) {
|
||||
|
||||
(*(lsn_t*)(arg+1)) = i;
|
||||
LogEntry * e = allocUpdateLogEntry(stasis_log(), -1, -1, OPERATION_LINEAR_HASH_INSERT, INVALID_PAGE,
|
||||
LogEntry * e = mallocScratchUpdateLogEntry(i, INVALID_LSN, INVALID_XID, OPERATION_LINEAR_HASH_INSERT, INVALID_PAGE,
|
||||
sizeof(linearHash_remove_arg) + sizeof(lsn_t) + sizeof(char));
|
||||
memcpy(stasis_log_entry_update_args_ptr(e), arg, sizeof(linearHash_remove_arg) + sizeof(lsn_t) + sizeof(char));
|
||||
|
||||
ThashInsert(xid, hash, (byte*)&i, sizeof(lsn_t), (byte*)e, sizeofLogEntry(0, e));
|
||||
|
||||
log->write_entry_done(log, e);
|
||||
free(e);
|
||||
|
||||
}
|
||||
|
||||
|
|
Loading…
Reference in a new issue