Fix 32395. The change in behavior of SetReuseConnection had cause ftp

handler to leak.
This commit is contained in:
ruslan%netscape.com 2000-03-19 00:07:17 +00:00
Родитель 0a83713ee9
Коммит c41f6dc16a
1 изменённых файлов: 6 добавлений и 3 удалений

Просмотреть файл

@ -422,7 +422,6 @@ nsresult nsSocketTransport::Process(PRInt16 aSelectFlags)
if (NS_SUCCEEDED (IsAlive (0, &isalive)) && !isalive)
{
CloseConnection ();
mCloseConnectionOnceDone = PR_FALSE;
mCurrentState = eSocketState_WaitConnect;
mLastReuseCount = mReuseCount;
@ -1293,6 +1292,9 @@ NS_IMPL_THREADSAFE_ISUPPORTS5(nsSocketTransport,
NS_IMETHODIMP
nsSocketTransport::GetReuseConnection(PRBool *_retval)
{
if (_retval == NULL)
return NS_ERROR_FAILURE;
*_retval = !mCloseConnectionOnceDone;
return NS_OK;
}
@ -1300,10 +1302,11 @@ nsSocketTransport::GetReuseConnection(PRBool *_retval)
NS_IMETHODIMP
nsSocketTransport::SetReuseConnection(PRBool aReuse)
{
mCloseConnectionOnceDone = !aReuse;
if (aReuse)
{
mReuseCount++;
}
return NS_OK;
}