diff --git a/mailnews/local/src/nsLocalMailFolder.cpp b/mailnews/local/src/nsLocalMailFolder.cpp index ba34632b766..9a18ea58a49 100644 --- a/mailnews/local/src/nsLocalMailFolder.cpp +++ b/mailnews/local/src/nsLocalMailFolder.cpp @@ -2239,6 +2239,19 @@ NS_IMETHODIMP nsMsgLocalMailFolder::EndCopy(PRBool copySucceeded) { // we are the destination folder for a move/copy nsresult rv = copySucceeded ? NS_OK : NS_ERROR_FAILURE; + if (!mCopyState) return NS_OK; + if (!copySucceeded) + { + if (mCopyState->m_fileStream) + mCopyState->m_fileStream->close(); + nsCOMPtr pathSpec; + rv = GetPath(getter_AddRefs(pathSpec)); + if (NS_SUCCEEDED(rv) && pathSpec) + pathSpec->Truncate(mCopyState->m_curDstKey); + ClearCopyState(PR_FALSE); + return NS_OK; + } + nsCOMPtr localUndoTxn; nsCOMPtr msgWindow; PRBool multipleCopiesFinished = (mCopyState->m_curCopyIndex >= mCopyState->m_totalMsgCount); diff --git a/mailnews/local/src/nsMailboxProtocol.cpp b/mailnews/local/src/nsMailboxProtocol.cpp index 13bae22efbe..dd22b9df6ce 100644 --- a/mailnews/local/src/nsMailboxProtocol.cpp +++ b/mailnews/local/src/nsMailboxProtocol.cpp @@ -329,12 +329,6 @@ NS_IMETHODIMP nsMailboxProtocol::OnStopRequest(nsIRequest *request, nsISupports // is coming from netlib so they are never going to ping us again with on data available. This means // we'll never be going through the Process loop... - /* mscott - the NS_BINDING_ABORTED is a hack to get around a problem I have - with the necko code...it returns this and treats it as an error when - it really isn't an error! I'm trying to get them to change this. - */ - if (aStatus == NS_BINDING_ABORTED) - aStatus = NS_OK; if (m_multipleMsgMoveCopyStream) { m_multipleMsgMoveCopyStream->Close();