Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
HPCC-32960 Fix epoll memory corruption issues
Although the SelectItem 'items' array is protected by a CS, epoll_wait can receive pending events for SelectItems that have been deleted, which were then link counted and caused corruption. Like the select handler version, avoid deleting the SelectItem's when items are removed, instead mark them deleted and let the triggerselect() approach remove them on the main thread. Also fix a theoretical issue when adding a existing socket to CSocketEpollThread, it did not check other CSocketEpollThread's to see if it needed to be removed. (given default hdlPerThrd is UINT_MAX, it will not have happened). Signed-off-by: Jake Smith <jake.smith@lexisnexisrisk.com>
- Loading branch information