Update of /cvsroot/mahogany/M/src/mail
In directory usw-pr-cvs1:/tmp/cvs-serv22727/src/mail
Modified Files:
MailFolderCmn.cpp
Log Message:
hopefully fixed fatal bug which manifested itself when closing IMAP folders on program
exit
Index: MailFolderCmn.cpp
===================================================================
RCS file: /cvsroot/mahogany/M/src/mail/MailFolderCmn.cpp,v
retrieving revision 1.109
retrieving revision 1.110
diff -b -u -2 -r1.109 -r1.110
--- MailFolderCmn.cpp 14 Sep 2002 17:02:29 -0000 1.109
+++ MailFolderCmn.cpp 5 Oct 2002 14:52:47 -0000 1.110
@@ -377,6 +377,5 @@
// to it (MfCloseEntry has a lock), so this would be an error in ref
// counting (extra DecRef()) elsewhere
- ASSERT_MSG( !GetCloseEntry(mf),
- _T("adding a folder to MfCloser twice??") );
+ ASSERT_MSG( !HasFolder(mf), _T("adding a folder to MfCloser twice??") );
#endif // DEBUG_FOLDER_CLOSE
@@ -505,5 +504,5 @@
{
// don't keep folders alive artificially if we're going to terminate soon
- // anyhow - or if we didn't start up fully yet and gs_MailFolderCloser
+ // anyhow -- or if we didn't start up fully yet and gs_MailFolderCloser
// hadn't been created
if ( gs_MailFolderCloser && !mApplication->IsShuttingDown() )
@@ -562,17 +561,4 @@
MObjectRC::IncRef();
-
- // if the folder had been kept alive artificially before this IncRef(),
- // remove it from the keep alive list as now it will stay opened without our
- // help (notice that we must do it after closing base class IncRef or the
- // object would have been deleted when DecRef() is called implicitly below)
- if ( GetNRef() == 2 && gs_MailFolderCloser )
- {
- MfCloseEntry *entry = gs_MailFolderCloser->GetCloseEntry(this);
- if ( entry )
- {
- gs_MailFolderCloser->Remove(entry);
- }
- }
}
@@ -590,5 +576,5 @@
if ( GetNRef() == 1 )
{
- if ( gs_MailFolderCloser && gs_MailFolderCloser->GetCloseEntry(this) )
+ if ( gs_MailFolderCloser && gs_MailFolderCloser->HasFolder(this) )
{
// we will crash later when removing it from the list!
-------------------------------------------------------
This sf.net email is sponsored by:ThinkGeek
Welcome to geek heaven.
http://thinkgeek.com/sf
_______________________________________________
Mahogany-cvsupdates mailing list
[EMAIL PROTECTED]
https://lists.sourceforge.net/lists/listinfo/mahogany-cvsupdates