From db19ac7188a64996dc6d3fbcffa0554e536b85fc Mon Sep 17 00:00:00 2001 From: "bienvenu%netscape.com" Date: Wed, 4 Dec 2002 00:40:19 +0000 Subject: [PATCH] fix compact folder performance regression, r=cavin, sr=sspitzer 182262 --- mailnews/base/src/nsMsgFolderCompactor.cpp | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/mailnews/base/src/nsMsgFolderCompactor.cpp b/mailnews/base/src/nsMsgFolderCompactor.cpp index 98726f4db041..43a0eb93dfe0 100644 --- a/mailnews/base/src/nsMsgFolderCompactor.cpp +++ b/mailnews/base/src/nsMsgFolderCompactor.cpp @@ -680,8 +680,10 @@ nsFolderCompactState::StartMessage() NS_ASSERTION(m_fileStream, "Fatal, null m_fileStream...\n"); if (m_fileStream) { + // this will force an internal flush, but not a sync. Tell should really do an internal flush, + // but it doesn't, and I'm afraid to change that nsIFileStream.cpp code anymore. + m_fileStream->seek(PR_SEEK_CUR, 0); // record the new message key for the message - m_fileStream->flush(); m_startOfNewMsg = m_fileStream->tell(); rv = NS_OK; }