fix news connection cache with busy connections, r/sr == mscott,sspitzer 65927

This commit is contained in:
bienvenu%netscape.com 2001-01-30 01:36:03 +00:00
Родитель 66dccc5cf8
Коммит fe3c7a7b68
1 изменённых файлов: 2 добавлений и 2 удалений

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

@ -494,7 +494,7 @@ nsNntpIncomingServer::GetNntpConnection(nsIURI * aUri, nsIMsgWindow *aMsgWindow,
nsresult rv = NS_OK;
nsCOMPtr<nsINNTPProtocol> connection;
nsCOMPtr<nsINNTPProtocol> freeConnection;
PRBool isBusy = PR_FALSE;
PRBool isBusy = PR_TRUE;
PRInt32 maxConnections = 2; // default to be 2
@ -517,7 +517,7 @@ nsNntpIncomingServer::GetNntpConnection(nsIURI * aUri, nsIMsgWindow *aMsgWindow,
rv = m_connectionCache->Count(&cnt);
if (NS_FAILED(rv)) return rv;
for (PRUint32 i = 0; i < cnt && !isBusy; i++)
for (PRUint32 i = 0; i < cnt && isBusy; i++)
{
aSupport = getter_AddRefs(m_connectionCache->ElementAt(i));
connection = do_QueryInterface(aSupport);