Bug 383716 - nsWebBrowserPersist::OnStopRequest doesn't check |status| for failure

p=Edward Lee (Mardak) <edilee@mozilla.com>
r=biesi, sr=bz
This commit is contained in:
asqueella@gmail.com 2007-07-23 16:34:20 -07:00
parent cb307ac952
commit 4e0cdb052a

View File

@ -713,6 +713,9 @@ NS_IMETHODIMP nsWebBrowserPersist::OnStopRequest(
OutputData *data = (OutputData *) mOutputMap.Get(&key);
if (data)
{
if (NS_SUCCEEDED(mPersistResult) && NS_FAILED(status))
SendErrorStatusChange(PR_TRUE, status, request, data->mFile);
#if defined(XP_OS2)
// delete 'data'; this will close the stream and let
// us tag the file it created with its source URI
@ -773,7 +776,7 @@ NS_IMETHODIMP nsWebBrowserPersist::OnStopRequest(
if (completed)
{
// we're all done, do our cleanup
EndDownload(NS_OK);
EndDownload(status);
}
if (mProgressListener)