diff options
Diffstat (limited to 'src/third_party/wiredtiger/src/session/session_api.c')
-rw-r--r-- | src/third_party/wiredtiger/src/session/session_api.c | 10 |
1 files changed, 6 insertions, 4 deletions
diff --git a/src/third_party/wiredtiger/src/session/session_api.c b/src/third_party/wiredtiger/src/session/session_api.c index bbe5d2a0218..fd091cb5b13 100644 --- a/src/third_party/wiredtiger/src/session/session_api.c +++ b/src/third_party/wiredtiger/src/session/session_api.c @@ -1467,7 +1467,9 @@ __session_commit_transaction(WT_SESSION *wt_session, const char *config) txn = &session->txn; if (F_ISSET(txn, WT_TXN_ERROR) && txn->mod_count != 0) WT_ERR_MSG(session, EINVAL, - "failed transaction requires rollback"); + "failed transaction requires rollback%s%s", + txn->rollback_reason == NULL ? "" : ": ", + txn->rollback_reason == NULL ? "" : txn->rollback_reason); if (ret == 0) ret = __wt_txn_commit(session, cfg); @@ -1628,14 +1630,14 @@ __session_transaction_sync(WT_SESSION *wt_session, const char *config) * Keep checking the LSNs until we find it is stable or we reach * our timeout, or there's some other reason to quit. */ - time_start = __wt_rdtsc(session); + time_start = __wt_clock(session); while (__wt_log_cmp(&session->bg_sync_lsn, &log->sync_lsn) > 0) { if (!__transaction_sync_run_chk(session)) WT_ERR(ETIMEDOUT); __wt_cond_signal(session, conn->log_file_cond); - time_stop = __wt_rdtsc(session); - waited_ms = WT_TSCDIFF_MS(time_stop, time_start); + time_stop = __wt_clock(session); + waited_ms = WT_CLOCKDIFF_MS(time_stop, time_start); if (waited_ms < timeout_ms) { remaining_usec = (timeout_ms - waited_ms) * WT_THOUSAND; __wt_cond_wait(session, log->log_sync_cond, |