mirror of
https://gitee.com/openharmony/third_party_ffmpeg
synced 2024-11-23 19:30:05 +00:00
os_support: fix poll() implementation
Our poll implementation does not iterate over the pollfd array properly while setting the revents. Signed-off-by: Luca Barbato <lu_zero@gentoo.org>
This commit is contained in:
parent
737eb5976f
commit
9ac2085dbf
@ -292,7 +292,7 @@ int poll(struct pollfd *fds, nfds_t numfds, int timeout)
|
||||
if (rc < 0)
|
||||
return rc;
|
||||
|
||||
for(i = 0; i < (nfds_t) n; i++) {
|
||||
for(i = 0; i < numfds; i++) {
|
||||
fds[i].revents = 0;
|
||||
|
||||
if (FD_ISSET(fds[i].fd, &read_set)) fds[i].revents |= POLLIN;
|
||||
|
Loading…
Reference in New Issue
Block a user