ipsservices/ipssosplugin/src/ipsplgmsgmapper.cpp
changeset 1 12c456ceeff2
parent 0 8466d47a6819
child 3 a4d6f1ea0416
equal deleted inserted replaced
0:8466d47a6819 1:12c456ceeff2
   188             {
   188             {
   189             CMsvStore* store( NULL );
   189             CMsvStore* store( NULL );
   190             CMsvEntry* cEntry = iSession.GetEntryL( aEntry.Id() );
   190             CMsvEntry* cEntry = iSession.GetEntryL( aEntry.Id() );
   191             CleanupStack::PushL( cEntry );
   191             CleanupStack::PushL( cEntry );
   192 
   192 
   193             if ( cEntry && cEntry->HasStoreL() )
   193             if ( cEntry )
   194                 {
   194             	{
   195                 store = cEntry->ReadStoreL();
   195             	if ( cEntry->HasStoreL() )
   196                 CleanupStack::PushL( store );
   196 					{
   197                 }
   197 					store = cEntry->ReadStoreL();
   198 
   198 					CleanupStack::PushL( store );
   199             SetEnvelopeL( cEntry, store, *result );
   199 					}
   200 
   200 
   201             // Apparently, this should be done only with
   201 				SetEnvelopeL( cEntry, store, *result );
   202             // EFSMsgDataStructure, but EFSMsgDataEnvelope is currently
   202 	
   203             // used by assuming that it reads also the content-type of
   203 				// Apparently, this should be done only with
   204             // the message
   204 				// EFSMsgDataStructure, but EFSMsgDataEnvelope is currently
   205             SetStructureL( cEntry, *result );
   205 				// used by assuming that it reads also the content-type of
   206 
   206 				// the message
   207             if ( store )
   207 				SetStructureL( cEntry, *result );
   208                 {
   208 	
   209                 CleanupStack::PopAndDestroy( store );
   209 				if ( store )
   210                 }
   210 					{
   211             CleanupStack::PopAndDestroy( cEntry );
   211 					CleanupStack::PopAndDestroy( store );
       
   212 					}
       
   213 				CleanupStack::PopAndDestroy( cEntry );
       
   214             	}
   212             break;
   215             break;
   213             }
   216             }
   214         case EFSMsgDataIdOnly:
   217         case EFSMsgDataIdOnly:
   215         default:
   218         default:
   216             break;
   219             break;
  1359             {
  1362             {
  1360             result->SetFetchedContentSize( 0 );
  1363             result->SetFetchedContentSize( 0 );
  1361             }
  1364             }
  1362         result->SetMailBoxId( aMailBoxId );
  1365         result->SetMailBoxId( aMailBoxId );
  1363         CleanupStack::PopAndDestroy(store);
  1366         CleanupStack::PopAndDestroy(store);
       
  1367         
       
  1368         SetFetchStateL( aEntry, aMessageId.Id(), ETrue, *result );
  1364         CleanupStack::Pop( result );
  1369         CleanupStack::Pop( result );
  1365         }
  1370         }
  1366     SetFetchStateL( aEntry, aMessageId.Id(), ETrue, *result );
       
  1367     CleanupStack::PopAndDestroy( cEntry );
  1371     CleanupStack::PopAndDestroy( cEntry );
  1368 
  1372 
  1369     return result;
  1373     return result;
  1370     }
  1374     }
  1371 
  1375