erts: Fix bug in unlimited fd_set patch
erts: Refactor unlimited select patch

An attempt to beautify the code by reducing the amount of #ifdef's
in the hot code path.