Multiple dispatch_io operations are usually running
simultaneously. When recreating the inspector listening
socket after an "AttachRequest" notification from {N} CLI,
the following crash happened in a dispather worker thread:
BUG IN CLIENT OF LIBDISPATCH: Unexpected EV_VANISHED (do not destroy random mach ports or file descriptors)
The reason turned out to be that we always have at least 2 pending
current operations. One is reading the next message,
and the other one -- the cleanup handler from dispatch_io_create.
[x] There is an issue for the bug/feature this PR is for. To avoid wasting your time, it's best to open a suggestion issue first and wait for approval before working on it.
Multiple dispatch_io operations are usually running simultaneously. When recreating the inspector listening socket after an "AttachRequest" notification from {N} CLI, the following crash happened in a dispather worker thread:
BUG IN CLIENT OF LIBDISPATCH: Unexpected EV_VANISHED (do not destroy random mach ports or file descriptors)
The reason turned out to be that we always have at least 2 pending current operations. One is reading the next message, and the other one -- the cleanup handler from
dispatch_io_create
.PR Checklist
refs #1254