dispatcher: fix issue #415
dispatcher: fix issue #415

A race condition during shutdown of sockets could result in a invalid
flag from poll, resulting in an accept() error.  Check the returned
array from poll is matching the current set of listeners before
accepting connections from them, as to avoid this problem.

Signed-off-by: Fabian Groffen <2c4829061e3ecacc1da315323749610b9ffaef65@gentoo.org>

grobian/carbon-c-relay,grobian/carbon-c-relay,grobian/carbon-c-relay