-
Notifications
You must be signed in to change notification settings - Fork 53
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
fix crash after reading from fd > 1024 (#267)
The socket selector holds a `seq` of per-descriptor data. When a reader is registered, a pointer to a seq item is stored - when the `seq` grows, this pointer becomes dangling and causes crashes like status-im/nimbus-eth2#3521. It turns out that there already exist two mechanisms for passing user data around - this PR simply removes one of them, saving on memory usage and removing the need to store pointers to the `seq` data that become dangling on resize.
- Loading branch information
1 parent
ae2a877
commit bb4c329
Showing
4 changed files
with
69 additions
and
82 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Oops, something went wrong.