mirror of
https://github.com/RT-Thread/rt-thread.git
synced 2025-01-18 15:43:32 +08:00
Update select.c
This commit is contained in:
parent
c90b449dac
commit
18510fa80f
@ -28,7 +28,7 @@
|
|||||||
#include <dfs_poll.h>
|
#include <dfs_poll.h>
|
||||||
#include <dfs_select.h>
|
#include <dfs_select.h>
|
||||||
|
|
||||||
static void fdzero(fd_set *set, int nfds)
|
static void fdszero(fd_set *set, int nfds)
|
||||||
{
|
{
|
||||||
fd_mask *m;
|
fd_mask *m;
|
||||||
int n;
|
int n;
|
||||||
@ -130,17 +130,17 @@ int select(int nfds, fd_set *readfds, fd_set *writefds, fd_set *exceptfds, struc
|
|||||||
/* Now set up the return values */
|
/* Now set up the return values */
|
||||||
if (readfds)
|
if (readfds)
|
||||||
{
|
{
|
||||||
fdzero(readfds, nfds);
|
fdszero(readfds, nfds);
|
||||||
}
|
}
|
||||||
|
|
||||||
if (writefds)
|
if (writefds)
|
||||||
{
|
{
|
||||||
fdzero(writefds, nfds);
|
fdszero(writefds, nfds);
|
||||||
}
|
}
|
||||||
|
|
||||||
if (exceptfds)
|
if (exceptfds)
|
||||||
{
|
{
|
||||||
fdzero(exceptfds, nfds);
|
fdszero(exceptfds, nfds);
|
||||||
}
|
}
|
||||||
|
|
||||||
/* Convert the poll descriptor list back into selects 3 bitsets */
|
/* Convert the poll descriptor list back into selects 3 bitsets */
|
||||||
|
Loading…
x
Reference in New Issue
Block a user