CNIOWindows: add stubs for `sendmmsg` and `recvmmsg` (#1645)

These need to be filled out, but lets stub them out for the time being
to get the symbol resolution sorted out.  These are possible to
implement using the WinSDK.
This commit is contained in:
Saleem Abdulrasool 2020-09-23 02:48:02 -07:00 committed by GitHub
parent 801b879b35
commit e183143648
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
2 changed files with 17 additions and 0 deletions

View File

@ -18,6 +18,7 @@
#if defined(_WIN32)
#include <WinSock2.h>
#include <time.h>
#define NIO(name) CNIOWindows_ ## name
@ -59,6 +60,11 @@ NIO(sendto)(SOCKET s, const void *buf, int len, int flags, const SOCKADDR *to,
return sendto(s, buf, len, flags, to, tolen);
}
int NIO(sendmmsg)(SOCKET s, NIO(mmsghdr) *msgvec, unsigned int vlen, int flags);
int NIO(recvmmsg)(SOCKET s, NIO(mmsghdr) *msgvec, unsigned int vlen, int flags,
struct timespec *timeout);
#undef NIO
#endif

View File

@ -16,4 +16,15 @@
#include "CNIOWindows.h"
int NIO(sendmmsg)(SOCKET s, NIO(mmsghdr) *msgvec, unsigned int vlen, int flags) {
assert(!"sendmmsg not implemented");
abort();
}
int NIO(recvmmsg)(SOCKET s, NIO(mmsghdr) *msgvec, unsigned int vlen, int flags,
struct timespec *timeout) {
assert(!"recvmmsg not implemented");
abort();
}
#endif