static void pollfds_poll(GArray *pollfds, int nfds, fd_set *rfds,

                         fd_set *wfds, fd_set *xfds)

{

    int i;



    for (i = 0; i < pollfds->len; i++) {

        GPollFD *pfd = &g_array_index(pollfds, GPollFD, i);

        int fd = pfd->fd;

        int revents = 0;



        if (FD_ISSET(fd, rfds)) {

            revents |= G_IO_IN | G_IO_HUP | G_IO_ERR;

        }

        if (FD_ISSET(fd, wfds)) {

            revents |= G_IO_OUT | G_IO_ERR;

        }

        if (FD_ISSET(fd, xfds)) {

            revents |= G_IO_PRI;

        }

        pfd->revents = revents & pfd->events;

    }

}

static void pollfds_poll(GArray *pollfds, int nfds, fd_set *rfds,

                         fd_set *wfds, fd_set *xfds)

{

    int i;



    for (i = 0; i < pollfds->len; i++) {

        GPollFD *pfd = &g_array_index(pollfds, GPollFD, i);

        int fd = pfd->fd;

        int revents = 0;



        if (FD_ISSET(fd, rfds)) {

            revents |= G_IO_IN | G_IO_HUP | G_IO_ERR;

        }

        if (FD_ISSET(fd, wfds)) {

            revents |= G_IO_OUT | G_IO_ERR;

        }

        if (FD_ISSET(fd, xfds)) {

            revents |= G_IO_PRI;

        }

        pfd->revents = revents & pfd->events;

    }

}

            revents |= G_IO_IN | G_IO_HUP | G_IO_ERR;             revents |= G_IO_OUT | G_IO_ERR;
static void FUNC_0(GArray *VAR_0, int VAR_1, fd_set *VAR_2,

                         fd_set *VAR_3, fd_set *VAR_4)

{

    int VAR_5;



    for (VAR_5 = 0; VAR_5 < VAR_0->len; VAR_5++) {

        GPollFD *pfd = &g_array_index(VAR_0, GPollFD, VAR_5);

        int fd = pfd->fd;

        int revents = 0;



        if (FD_ISSET(fd, VAR_2)) {

            revents |= G_IO_IN | G_IO_HUP | G_IO_ERR;

        }

        if (FD_ISSET(fd, VAR_3)) {

            revents |= G_IO_OUT | G_IO_ERR;

        }

        if (FD_ISSET(fd, VAR_4)) {

            revents |= G_IO_PRI;

        }

        pfd->revents = revents & pfd->events;

    }

}

static void FUNC_0(GArray *VAR_0, int VAR_1, fd_set *VAR_2,
fd_set *VAR_3, fd_set *VAR_4)
{ int VAR_5; for (VAR_5 = 0; VAR_5 < VAR_0->len; VAR_5++) { GPollFD *pfd = &g_array_index(VAR_0, GPollFD, VAR_5); int fd = pfd->fd; int revents = 0; if (FD_ISSET(fd, VAR_2)) { revents |= G_IO_IN | G_IO_HUP | G_IO_ERR; } if (FD_ISSET(fd, VAR_3)) { revents |= G_IO_OUT | G_IO_ERR; } if (FD_ISSET(fd, VAR_4)) { revents |= G_IO_PRI; } pfd->revents = revents & pfd->events; } }