Browse Source

Fix Windows build: use WSAPoll instead of poll for linking

nodeinfo-routing-update
Evgeny 2 months ago
parent
commit
0798b149ab
  1. 4
      lib/platform_compat.h

4
lib/platform_compat.h

@ -103,8 +103,8 @@
// nanosleep already defined in pthread_time.h on MSYS2 // nanosleep already defined in pthread_time.h on MSYS2
// poll() and pollfd already defined in winsock2.h on MSYS2 // poll() and pollfd already defined in winsock2.h on MSYS2
// Explicitly declare poll() to avoid implicit declaration warning // Use WSAPoll on Windows (available in Vista and later)
int poll(struct pollfd *fds, unsigned long nfds, int timeout); #define poll WSAPoll
// sa_family_t might not be defined on some Windows setups // sa_family_t might not be defined on some Windows setups
#ifndef sa_family_t #ifndef sa_family_t

Loading…
Cancel
Save