Uploaded image for project: 'Core Server'
  1. Core Server
  2. SERVER-28977

Coverity analysis defect 101508: Data race condition

    XMLWordPrintable

    Details

    • Type: Bug
    • Status: Closed
    • Priority: Major - P3
    • Resolution: Fixed
    • Affects Version/s: None
    • Fix Version/s: 4.3.1, 4.2.3
    • Component/s: Storage
    • Labels:
    • Backwards Compatibility:
      Fully Compatible
    • Operating System:
      ALL
    • Backport Requested:
      v4.2
    • Sprint:
      Execution Team 2019-06-17

      Description

      Thread shared data is accessed without holding an appropriate lock, possibly causing a race condition

      Defect 101508 (STATIC_C)
      Checker MISSING_LOCK (subcategory none)
      File: /src/mongo/db/storage/ephemeral_for_test/ephemeral_for_test_record_store.h
      Function mongo::EphemeralForTestRecordStore::updateStatsAfterRepair(mongo::OperationContext *, long long, long long)
      /src/mongo/db/storage/ephemeral_for_test/ephemeral_for_test_record_store.h, line: 132
      Accessing "this->_data->dataSize" without holding lock "mongo::EphemeralForTestRecordStore::Data.recordsMutex". Elsewhere, "_ZN5mongo27EphemeralForTestRecordStore4DataE.dataSize" is accessed with "mongo::EphemeralForTestRecordStore::Data.recordsMutex" held 7 out of 9 times.

                  _data->dataSize = dataSize;

        Attachments

          Activity

            People

            Assignee:
            zach.yam Zach Yam (Inactive)
            Reporter:
            xgen-internal-coverity Coverity Collector User
            Participants:
            Votes:
            0 Vote for this issue
            Watchers:
            5 Start watching this issue

              Dates

              Created:
              Updated:
              Resolved: