Refactored for fd -> socket indexing, multiserver