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

Coverity analysis defect 76790: Wrapper object use after free

    XMLWordPrintableJSON

Details

    • Icon: Bug Bug
    • Resolution: Won't Fix
    • Icon: Major - P3 Major - P3
    • None
    • None
    • Replication
    • Fully Compatible
    • ALL

    Description

      An internal pointer of a wrapper object remains available after the object is freed

      Defect 76790 (STATIC_C)
      Checker WRAPPER_ESCAPE (subcategory none)
      File: /src/mongo/db/repl/sync_tail.cpp
      Function mongo::repl::multiSyncApply(const std::vector<mongo::BSONObj, std::allocator<mongo::BSONObj>> &, mongo::repl::SyncTail *)
      /src/mongo/db/repl/sync_tail.cpp, line: 1014
      The internal representation of local "oplogEntries" escapes into "oplogEntryPointers[i]", but is destroyed when it exits scope.

                  oplogEntryPointers[i] = &oplogEntries[i];

      Attachments

        Activity

          People

            scotthernandez Scott Hernandez (Inactive)
            xgen-internal-coverity Coverity Collector User
            Votes:
            0 Vote for this issue
            Watchers:
            4 Start watching this issue

            Dates

              Created:
              Updated:
              Resolved: