Thanks to visit codestin.com
Credit goes to github.com

Skip to content

Fixes for compile and work in Windows (with mingw) #80

@victor-zou

Description

@victor-zou
  1. need add definition _WIN32_WINNT for your window version (at leat 0x0600, or will not have WSAPoll)
  2. might need define WIN32_LEAN_AND_MEAN (not affected here, but might affect other places)
  3. get errno in the Windows socket world should use WSAGetLastError
  4. connect in non blocking mode will always return -1 and set errno WSAEWOULDBLOCK. I commented the SetNonBlock before the connects.
  5. a bug in gcc8 (at least fixed in gcc10), in the declaration of WSAPoll, a const void * signature missed const, neet add const_cast for fix

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions