Skip to content

Mingw32 error (poll was not declared) + strange "poll" def/undef in splitted header. #2106

@Chuvi-w

Description

@Chuvi-w

Here is #define poll.

#define poll(fds, nfds, timeout) WSAPoll(fds, nfds, timeout)

Here is #undef poll.
#undef poll

When splitted to httplib.cc and httplib.h files, "#define poll" and "#undef poll" remains in httplib.h file.
"poll" itself not used in splitted httplib.h, but in httplib.cc it comes after "#undef poll", if we have _WIN32 defined.

Seems that "#define poll" and "#undef poll" should be in "httplib.cc " when httplib.h is splitted into .h and .cc parts.

(I have no idea how or why it compiles in Windows.)

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions