mirror of
https://gitee.com/mirrors_PX4/PX4-Autopilot.git
synced 2026-10-30 03:43:35 +08:00
Clean-up files in fs/ directory
git-svn-id: https://nuttx.svn.sourceforge.net/svnroot/nuttx/trunk@4942 7fd9a85b-ad96-42d3-883c-3090e2eb8679
This commit is contained in:
@@ -114,7 +114,7 @@ int select(int nfds, FAR fd_set *readfds, FAR fd_set *writefds,
|
||||
pollset = (struct pollfd *)kzalloc(nfds * sizeof(struct pollfd));
|
||||
if (!pollset)
|
||||
{
|
||||
errno = ENOMEM;
|
||||
set_errno(ENOMEM);
|
||||
return ERROR;
|
||||
}
|
||||
|
||||
@@ -133,9 +133,9 @@ int select(int nfds, FAR fd_set *readfds, FAR fd_set *writefds,
|
||||
|
||||
if (readfds && FD_ISSET(fd, readfds))
|
||||
{
|
||||
pollset[npfds].fd = fd;
|
||||
pollset[npfds].events |= POLLIN;
|
||||
incr = 1;
|
||||
pollset[npfds].fd = fd;
|
||||
pollset[npfds].events |= POLLIN;
|
||||
incr = 1;
|
||||
}
|
||||
|
||||
/* The writefds set holds the set of FDs that the caller can be assured
|
||||
@@ -144,17 +144,17 @@ int select(int nfds, FAR fd_set *readfds, FAR fd_set *writefds,
|
||||
|
||||
if (writefds && FD_ISSET(fd, writefds))
|
||||
{
|
||||
pollset[npfds].fd = fd;
|
||||
pollset[npfds].events |= POLLOUT;
|
||||
incr = 1;
|
||||
pollset[npfds].fd = fd;
|
||||
pollset[npfds].events |= POLLOUT;
|
||||
incr = 1;
|
||||
}
|
||||
|
||||
/* The exceptfds set holds the set of FDs that are watched for exceptions */
|
||||
|
||||
if (exceptfds && FD_ISSET(fd, exceptfds))
|
||||
{
|
||||
pollset[npfds].fd = fd;
|
||||
incr = 1;
|
||||
pollset[npfds].fd = fd;
|
||||
incr = 1;
|
||||
}
|
||||
|
||||
npfds += incr;
|
||||
|
||||
Reference in New Issue
Block a user