fix problem attempting to connect after a connect failure