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

Coverity analysis defect 103374: Uninitialized scalar variable

    • Type: Icon: Bug Bug
    • Resolution: Fixed
    • Priority: Icon: Major - P3 Major - P3
    • 3.7.4
    • Affects Version/s: None
    • Component/s: Networking
    • Labels:
    • Fully Compatible
    • ALL
    • Platforms 2018-03-26

      Use of an uninitialized variable

      Defect 103374 (STATIC_C)
      Checker UNINIT (subcategory none)
      File: /src/mongo/transport/asio_utils.h
      Function mongo::transport::pollASIOSocket<asio::basic_stream_socket<asio::generic::stream_protocol>, int>(T1 &, T2, mongo::Duration<std::ratio<(long)1, (long)1000>>)
      /src/mongo/transport/asio_utils.h, line: 131
      Declaring variable "pollItem" without initializer.

              pollfd pollItem;
      

      /src/mongo/transport/asio_utils.h, line: 158
      Using uninitialized value "pollItem.revents".

              int revents = pollItem.revents;
      

            Assignee:
            jonathan.reams@mongodb.com Jonathan Reams
            Reporter:
            xgen-internal-coverity Coverity Collector User
            Votes:
            0 Vote for this issue
            Watchers:
            6 Start watching this issue

              Created:
              Updated:
              Resolved: