зеркало из https://github.com/mozilla/gecko-dev.git
Allowing the FTP channel to Cancel() even if the underlying connection thread has gone away.
This commit is contained in:
Родитель
f61465810a
Коммит
64a59be346
|
@ -134,8 +134,15 @@ nsFTPChannel::IsPending(PRBool *result) {
|
|||
|
||||
NS_IMETHODIMP
|
||||
nsFTPChannel::Cancel(void) {
|
||||
nsresult rv = NS_OK;
|
||||
// if we hit this assert, someone's hanging onto the channel too long.
|
||||
NS_ASSERTION(mConnThread, "lost the connection thread.");
|
||||
return mConnThread->Cancel();
|
||||
|
||||
// it's ok for this method to *not* have the underlying thread because
|
||||
// the user obviously want's the underlying channel/connection to go away.
|
||||
if (mConnThread)
|
||||
rv = mConnThread->Cancel();
|
||||
return rv;
|
||||
}
|
||||
|
||||
NS_IMETHODIMP
|
||||
|
|
Загрузка…
Ссылка в новой задаче