Sockets: check external FD_SETSIZE against number of sockets

This commit adds a compiler check to verify an external FD_SETSIZE has
enough space to store the configured number of sockets
This commit is contained in:
Joel Cunningham 2016-10-31 15:37:13 -05:00
parent a82ec4499f
commit d4384cfac4

View File

@ -428,6 +428,8 @@ typedef struct fd_set
#elif LWIP_SOCKET_OFFSET
#error LWIP_SOCKET_OFFSET does not work with external FD_SET!
#elif FD_SETSIZE < MEMP_NUM_NETCONN
#error "external FD_SETSIZE too small for number of sockets"
#endif /* FD_SET */
/** LWIP_TIMEVAL_PRIVATE: if you want to use the struct timeval provided