Skip to content

Commit

Permalink
fixes bug 192272 "Mozilla crashed on Quit after attempting access to SSL
Browse files Browse the repository at this point in the history
IMAP account during DNS hang [@ nsInputStreamPump::EnsureWaiting]"
r=sspitzer sr=bienvenu a=asa
  • Loading branch information
darin%netscape.com committed Feb 8, 2003
1 parent 245ee9f commit 0017e6b
Showing 1 changed file with 11 additions and 3 deletions.
14 changes: 11 additions & 3 deletions mailnews/imap/src/nsImapProtocol.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -961,7 +961,13 @@ NS_IMETHODIMP nsImapProtocol::Run()
}

me->m_runningUrl = nsnull;
me->m_transport = nsnull;
if (m_transport)
{
// make sure the transport closes (even if someone is still indirectly
// referencing it).
me->m_transport->Close(NS_ERROR_ABORT);
me->m_transport = nsnull;
}
me->m_inputStream = nsnull;
me->m_outputStream = nsnull;
me->m_channelListener = nsnull;
Expand Down Expand Up @@ -1069,8 +1075,10 @@ nsImapProtocol::TellThreadToDie(PRBool isSaveToClose)
}
}

if (m_pump)
m_pump->Cancel(NS_ERROR_ABORT);
// kill the socket connection
if (m_transport)
m_transport->Close(NS_ERROR_ABORT);

PR_EnterMonitor(m_threadDeathMonitor);
m_threadShouldDie = PR_TRUE;
PR_ExitMonitor(m_threadDeathMonitor);
Expand Down

0 comments on commit 0017e6b

Please sign in to comment.