fix memory leak copying multiple messages to an imap folder from a different account, 213688, sr=mscott

This commit is contained in:
bienvenu%nventure.com 2004-04-27 19:52:41 +00:00
Родитель 7846c8642e
Коммит 74b431fd1d
1 изменённых файлов: 2 добавлений и 1 удалений

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

@ -2874,7 +2874,8 @@ NS_IMETHODIMP nsImapMailFolder::BeginCopy(nsIMsgDBHdr *message)
if (NS_SUCCEEDED(rv) && m_copyState->m_tmpFileSpec)
rv = m_copyState->m_tmpFileSpec->OpenStreamForWriting();
m_copyState->m_dataBuffer = (char*) PR_CALLOC(COPY_BUFFER_SIZE+1);
if (!m_copyState->m_dataBuffer)
m_copyState->m_dataBuffer = (char*) PR_CALLOC(COPY_BUFFER_SIZE+1);
if (!m_copyState->m_dataBuffer)
return NS_ERROR_OUT_OF_MEMORY;
m_copyState->m_dataBufferSize = COPY_BUFFER_SIZE;