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

Take a shared_ptr to Trackers in IndexBuildsCoordinator before calling waitUntilNoIndexBuildsRemain

    XMLWordPrintableJSON

Details

    • Bug
    • Status: Closed
    • Major - P3
    • Resolution: Fixed
    • None
    • 4.1.9
    • Storage
    • None
    • Fully Compatible
    • ALL
    • Storage NYC 2019-03-11
    • 83

    Description

      We have memory errors in the IndexBuildsCoordinator's use of the CollectionIndexBuildsTracker and DatabaseIndexBuildsTracker objects where we call waitUntilNoIndexBuildsRemain through hash map iterators rather than acquiring a safe shared_ptr to call wait upon, leading to a use after free when the entry is removed from the hash map and the caller of waitUntilNoIndexBuildsRemain does not have a shared_ptr instance to keep the object in memory.

      Attachments

        Activity

          People

            dianna.hohensee@mongodb.com Dianna Hohensee
            dianna.hohensee@mongodb.com Dianna Hohensee
            Votes:
            0 Vote for this issue
            Watchers:
            1 Start watching this issue

            Dates

              Created:
              Updated:
              Resolved: