# HG changeset patch # User Dremov Kirill (Nokia-D-MSW/Tampere) # Date 1277127597 -10800 # Node ID 50d20108beab9dcc4ea90593dd67a0a3353807fe # Parent 1aa6688bfd6b7e68e33ad6488a664857a5587635 Revision: 201022 Kit: 2010125 diff -r 1aa6688bfd6b -r 50d20108beab serviceproviders/sapi_contacts_vpbk/tsrc/dev/tcontacts_async/src/tcontacts_async_blocks.cpp --- a/serviceproviders/sapi_contacts_vpbk/tsrc/dev/tcontacts_async/src/tcontacts_async_blocks.cpp Tue May 25 13:38:11 2010 +0300 +++ b/serviceproviders/sapi_contacts_vpbk/tsrc/dev/tcontacts_async/src/tcontacts_async_blocks.cpp Mon Jun 21 16:39:57 2010 +0300 @@ -112,7 +112,11 @@ } void CContactsUT::HandleReturnId( const TInt& aError, HBufC8* acntId, TInt aTransId ) { + delete acntId; CActiveScheduler::Stop(); + if(aError == KErrNone) + iErr = KErrNone; + } void CContactsUT::HandleReturnArray(const TInt& aError, RPointerArray& aArray, TInt aTransId ) @@ -203,10 +207,11 @@ iLog->Log(_L("Phone Contact Field modified \n")); __UHEAP_MARK; iServiceHandle->AddL(this,0,singleContact); + __UHEAP_MARKEND; + iLog->Log(_L("AddL called\n")); iLog->Log(_L("Start Active Scheduler\n")); CActiveScheduler::Start(); - __UHEAP_MARKEND; break; } } @@ -660,7 +665,7 @@ iErr = KErrNone; - __UHEAP_MARK; + // __UHEAP_MARK; iOp = iContactManager->MatchPhoneNumberL( KPhoneNumber, KPhoneNumber().Length(), *this ); CActiveScheduler::Start(); @@ -686,7 +691,7 @@ iContactToDelete = NULL; - __UHEAP_MARKEND; + // __UHEAP_MARKEND; } //Add 1 contact @@ -3156,7 +3161,7 @@ { while(count) { - //__UHEAP_MARK; + __UHEAP_MARK; iBuffer = (const_cast(iFindResults->At(--count))).PackLC(); CleanupStack::Pop();//iBuffer iServiceHandle = CContactService::NewL(); @@ -3171,7 +3176,7 @@ delete iServiceHandle;//serviceHandle iServiceHandle = NULL; iLog->Log( KServiceClose ); - //__UHEAP_MARKEND; + __UHEAP_MARKEND; } } diff -r 1aa6688bfd6b -r 50d20108beab serviceproviders/sapi_contacts_vpbk/tsrc/testing/tcontact_getlist/src/tcontact_getlistblocks.cpp --- a/serviceproviders/sapi_contacts_vpbk/tsrc/testing/tcontact_getlist/src/tcontact_getlistblocks.cpp Tue May 25 13:38:11 2010 +0300 +++ b/serviceproviders/sapi_contacts_vpbk/tsrc/testing/tcontact_getlist/src/tcontact_getlistblocks.cpp Mon Jun 21 16:39:57 2010 +0300 @@ -619,10 +619,6 @@ CContactIter* iter = CContactIter::NewL(); icontactservice->GetListL(*iter); - delete iter; - delete icallback; - delete icontactservice; - __UHEAP_MARKEND; TPtrC buf(_L("")); iter->NextL(buf); @@ -631,16 +627,15 @@ { count++; iter->NextL(buf); } - if(count==2) - { + delete iter; + delete icallback; + delete icontactservice; + __UHEAP_MARKEND; + if(count==2) return KErrNone ; - } -delete iter; - delete icallback; - delete icontactservice; - //__UHEAP_MARKEND; - return KErrGeneral; + else + return KErrGeneral; } /* get all contacts from the phonebook ie contacts.cdb,manual*/