Uploaded image for project: 'WiredTiger'
  1. WiredTiger
  2. WT-12838

Fix write lock release in __checkpoint_prepare

    • Storage Engines
    • 2
    • 나비 (nabi) - 2024-04-16

      checkpoint_prepare incorrectly releases a readlock in this error case:

        /* A checkpoint should never proceed when timestamps are out of order. */
        if (__wt_atomic_loadbool(&txn_global->has_oldest_timestamp) &&
           txn_global->oldest_timestamp > txn_global->stable_timestamp) {
               __wt_readunlock(session, &txn_global->rwlock);
      

      This should be a _wt_writeunlock not _wt_readunlock as that is the lock we are holding at the time.

            Assignee:
            sean.watt@mongodb.com Sean Watt
            Reporter:
            sean.watt@mongodb.com Sean Watt
            Votes:
            0 Vote for this issue
            Watchers:
            3 Start watching this issue

              Created:
              Updated:
              Resolved: