Multiple socket handling