mirror of
https://github.com/mozilla/gecko-dev.git
synced 2025-02-03 12:35:58 +00:00
part of fix for problems saving imap messages offline as templates, rs=sspitzer 81690
This commit is contained in:
parent
e51414a486
commit
4b3f5e162f
@ -516,13 +516,18 @@ NS_IMETHODIMP nsMailDatabase::GetOfflineOpForKey(nsMsgKey msgKey, PRBool create,
|
||||
nsIMdbRow *offlineOpRow;
|
||||
err = m_mdbStore->GetRow(GetEnv(), &rowObjectId, &offlineOpRow);
|
||||
|
||||
if (!offlineOpRow && create)
|
||||
if (create)
|
||||
{
|
||||
err = m_mdbStore->NewRowWithOid(GetEnv(), &rowObjectId, &offlineOpRow);
|
||||
NS_ENSURE_SUCCESS(err, err);
|
||||
if (offlineOpRow)
|
||||
if (!offlineOpRow)
|
||||
{
|
||||
err = m_mdbStore->NewRowWithOid(GetEnv(), &rowObjectId, &offlineOpRow);
|
||||
NS_ENSURE_SUCCESS(err, err);
|
||||
}
|
||||
if (offlineOpRow && !hasOid)
|
||||
{
|
||||
m_mdbAllOfflineOpsTable->AddRow(GetEnv(), offlineOpRow);
|
||||
newOp = PR_TRUE;
|
||||
newOp = PR_TRUE;
|
||||
}
|
||||
}
|
||||
|
||||
if (err == NS_OK && offlineOpRow)
|
||||
|
Loading…
x
Reference in New Issue
Block a user