Uploaded image for project: 'C Driver'
  1. C Driver
  2. CDRIVER-911

Coverity analysis defect 76551: Unused value

    • Type: Icon: Bug Bug
    • Resolution: Done
    • Priority: Icon: Major - P3 Major - P3
    • 1.3.0-beta0
    • Affects Version/s: None
    • Component/s: None
    • None

      A value assigned to a variable is never used.

      Defect 76551 (STATIC_C)
      Checker UNUSED_VALUE (subcategory none)
      File: /src/mongoc/mongoc-cluster.c
      Function _mongoc_cluster_auth_node_x509
      /src/mongoc/mongoc-cluster.c, line: 860
      Overwriting previous write to "username" with value from "mongoc_uri_get_username(cluster->uri)".

             username = mongoc_uri_get_username (cluster->uri);
      

      /src/mongoc/mongoc-cluster.c, line: 850
      Assigning value from """" to "username" here, but that stored value is overwritten before it can be used.

             const char *username = "";
      

            Assignee:
            bjori Hannes Magnusson
            Reporter:
            xgen-internal-coverity Coverity Collector User
            Votes:
            0 Vote for this issue
            Watchers:
            0 Start watching this issue

              Created:
              Updated:
              Resolved: