Coverity analysis defect 101971: Resource leak

XMLWordPrintableJSON

    • Type: Bug
    • Resolution: Fixed
    • Priority: Minor - P4
    • 1.8.0
    • Affects Version/s: None
    • Component/s: None
    • None
    • None
    • None
    • None
    • None
    • None
    • None
    • None

      Leak of memory or pointers to system resources

      Defect 101971 (STATIC_C)
      Checker RESOURCE_LEAK (subcategory none)
      File: /src/mongoc/mongoc-client.c
      Function mongoc_client_kill_cursor
      /src/mongoc/mongoc-client.c, line: 1840
      Assigning: "read_prefs" = storage returned from "mongoc_read_prefs_new(MONGOC_READ_PRIMARY)".

             read_prefs = mongoc_read_prefs_new (MONGOC_READ_PRIMARY);
      

      /src/mongoc/mongoc-client.c, line: 1846
      Variable "read_prefs" going out of scope leaks the storage it points to.

                return;
      

              Assignee:
              A. Jesse Jiryu Davis
              Reporter:
              Coverity Collector User
              Votes:
              0 Vote for this issue
              Watchers:
              1 Start watching this issue

                Created:
                Updated:
                Resolved: