Clean up NetworkIO code