serviceproviders/sapi_contacts_vpbk/src/contactinterface.cpp
branchRCL_3
changeset 56 c210248fa89d
parent 38 02682e02e51f
child 65 0b68a1b0c15e
--- a/serviceproviders/sapi_contacts_vpbk/src/contactinterface.cpp	Wed Mar 31 23:02:09 2010 +0300
+++ b/serviceproviders/sapi_contacts_vpbk/src/contactinterface.cpp	Tue Apr 27 17:33:05 2010 +0300
@@ -406,7 +406,12 @@
     //iDburi = HBufC::NewL(VPbkContactStoreUris::DefaultCntDbUri().Length());    
     //set the DBUri to the default value.    
     //iDburi->Des().Copy(VPbkContactStoreUris::DefaultCntDbUri());
-    iDburi = GetDefaultDBUri().AllocLC();
+    if(iDburi)
+    	{
+      delete iDburi;
+      iDburi=NULL;
+      }
+    iDburi = GetDefaultDBUri().AllocL();   
     //get the number of entries in the map
     TInt keyCount = aMap->Count();
 
@@ -1778,7 +1783,7 @@
                     User::Leave(err);
                     }
                 } 
-            CleanupStack::Pop();
+            //CleanupStack::Pop();
             CleanupStack::Pop(contact);
             } //end of if pMap
         else