Coverity analysis defect 114987: Wrapper object use after free

XMLWordPrintableJSON

    • Fully Compatible
    • ALL
    • v4.4, v4.2, v4.0, v3.6
    • None
    • 3
    • None
    • None
    • None
    • None
    • None
    • None

      Wrapper object use after free

      A use after free bug would occur if the internal pointer is used. An internal pointer of a wrapper object remains available after the object is freed
      /src/mongo/db/pipeline/document_source_list_local_sessions.cpp:46: WRAPPER_ESCAPE 114987 Calling "back" which extracts wrapped state from "this->_ids".
      /src/mongo/db/pipeline/document_source_list_local_sessions.cpp:46: WRAPPER_ESCAPE 114987 Assigning: "id" = "this->_ids.back()".
      /src/mongo/db/pipeline/document_source_list_local_sessions.cpp:47: WRAPPER_ESCAPE 114987 Calling "pop_back" invalidates the internal representation of "this->_ids".
      /src/mongo/db/pipeline/document_source_list_local_sessions.cpp:49: WRAPPER_ESCAPE 114987 Using invalidated internal representation of "this->_ids".

            Assignee:
            Arun Banala
            Reporter:
            Coverity Collector User
            Votes:
            0 Vote for this issue
            Watchers:
            3 Start watching this issue

              Created:
              Updated:
              Resolved: