Skip to content

Conversation

bnoordhuis
Copy link
Contributor

It's not safe to add file descriptors > FD_SETSIZE (usually 1,024) to a fd_set, it writes beyond the buffer. Switch to poll(2).

Fixes: #1096

It's not safe to add file descriptors > FD_SETSIZE (usually 1,024) to
a fd_set, it writes beyond the buffer. Switch to poll(2).

Fixes: quickjs-ng#1096
Copy link
Contributor

@saghul saghul left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Nice one!

@bnoordhuis bnoordhuis merged commit f0849ad into quickjs-ng:master Jun 8, 2025
126 of 127 checks passed
@bnoordhuis bnoordhuis deleted the fix1096 branch June 8, 2025 19:45
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

Don't use select(2) in js_os_poll
2 participants