Fixed a crashing bug that would occur if mails were placed during an IMAP session in the root hierarchy of the IMAP directory structure with a non-NULL mailbox root prefix

git-svn-id: file:///srv/svn/repos/haiku/trunk/current@9837 a95241bf-73f2-0310-859d-f6bbb57e9c96
This commit is contained in:
Nathan Whitehorn 2004-11-07 21:50:46 +00:00
parent 6646684604
commit 40c831ab93
1 changed files with 6 additions and 0 deletions

View File

@ -177,6 +177,9 @@ class UpdateHandler : public BHandler {
if (dir == NULL)
dir = "";
if (!_prot->mailboxes.HasItem(dir))
break;
{
node_ref item_ref;
@ -315,6 +318,9 @@ void BRemoteMailStorageProtocol::SyncMailbox(const char *mailbox) {
uint32 chain;
bool append;
if (!mailboxes.HasItem(mailbox))
return; // -- Basic Sanity Checking
while (folder.GetNextEntry(&entry) == B_OK) {
if (!entry.IsFile())
continue;