Uploaded image for project: 'Thrift'
  1. Thrift
  2. THRIFT-3502

C++ TServerSocket passes small buffer to getsockname

    XMLWordPrintableJSON

    Details

    • Type: Bug
    • Status: Closed
    • Priority: Major
    • Resolution: Fixed
    • Affects Version/s: None
    • Fix Version/s: 0.10.0
    • Component/s: C++ - Library
    • Labels:
      None
    • Environment:

      Microsoft Visual Studio 2015

      Description

      TServerSocket::listen is using a struct sockaddr instead of a struct sockaddr_storage when calling getsockname. It then fails to get the bound port number when the configured port is 0. See the following stackoverflow post:

      http://stackoverflow.com/questions/14624427/wsaefault-error-when-use-getsockname-function

        Attachments

          Activity

            People

            • Assignee:
              Unassigned
              Reporter:
              jeremyspiegel Jeremy Spiegel
            • Votes:
              0 Vote for this issue
              Watchers:
              3 Start watching this issue

              Dates

              • Created:
                Updated:
                Resolved: