py3 compatibility
empty data means closed socket per TCP specs