VFS: Optionally disable the VFS implementation of select()

This allows to temporarily resolve issues like
https://github.com/espressif/esp-idf/issues/1987
while bugs are fixed in the VFS implementation of select().
This commit is contained in:
Roland Dobai
2018-05-23 08:25:46 +02:00
parent c9f8470fdf
commit 004bf84d8c
3 changed files with 23 additions and 0 deletions

View File

@@ -14,8 +14,17 @@
#include <sys/select.h>
#include "esp_vfs.h"
#include "sdkconfig.h"
#ifdef CONFIG_USE_ONLY_LWIP_SELECT
#include "lwip/sockets.h"
#endif
int select(int nfds, fd_set *readfds, fd_set *writefds, fd_set *errorfds, struct timeval *timeout)
{
#ifdef CONFIG_USE_ONLY_LWIP_SELECT
return lwip_select(nfds, readfds, writefds, errorfds, timeout);
#else
return esp_vfs_select(nfds, readfds, writefds, errorfds, timeout);
#endif
}