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

Coverity analysis defect 73299: Resource leak

    XMLWordPrintableJSON

Details

    • Icon: Bug Bug
    • Resolution: Done
    • Icon: Major - P3 Major - P3
    • None
    • 3.1.6
    • Security
    • Fully Compatible
    • ALL
    • Security 7 08/10/15

    Description

      Leak of memory or pointers to system resources

      Defect 73299 (STATIC_C)
      Checker RESOURCE_LEAK (subcategory none)
      File: /src/mongo/db/modules/enterprise/src/encryptdb/wiredtiger_encryption_callbacks.cpp
      Function mongo_addWiredTigerEncryptors
      /src/mongo/db/modules/enterprise/src/encryptdb/wiredtiger_encryption_callbacks.cpp, line: 244
      Storage is returned from allocation function "operator new".

              mongo::ExtendedWTEncryptor* extWTEncryptor = new mongo::ExtendedWTEncryptor;

      /src/mongo/db/modules/enterprise/src/encryptdb/wiredtiger_encryption_callbacks.cpp, line: 244
      Assigning: "extWTEncryptor" = storage returned from "new mongo::<unnamed>::ExtendedWTEncryptor".

              mongo::ExtendedWTEncryptor* extWTEncryptor = new mongo::ExtendedWTEncryptor;

      /src/mongo/db/modules/enterprise/src/encryptdb/wiredtiger_encryption_callbacks.cpp, line: 258
      Variable "extWTEncryptor" going out of scope leaks the storage it points to.

              return 0;

      Attachments

        Activity

          People

            andreas.nilsson Andreas Nilsson
            xgen-internal-coverity Coverity Collector User
            Votes:
            0 Vote for this issue
            Watchers:
            5 Start watching this issue

            Dates

              Created:
              Updated:
              Resolved: