engine/src/PodcastModel.cpp
changeset 74 add4bcf06298
parent 67 9c24c921ec35
child 89 9d854792013a
--- a/engine/src/PodcastModel.cpp	Wed Apr 28 14:38:03 2010 +0100
+++ b/engine/src/PodcastModel.cpp	Sat May 01 12:35:34 2010 +0100
@@ -72,21 +72,25 @@
 {
 	DP("CPodcastModel::ConstructL BEGIN");
 	User::LeaveIfError(iFsSession.Connect());
-	
 	iCommDB = CCommsDatabase::NewL (EDatabaseTypeUnspecified);
-	//iCommDB ->ShowHiddenRecords(); // magic
 	iIapNameArray = new (ELeave) CDesCArrayFlat(KDefaultGranu);
 	iSNAPNameArray = new (ELeave) CDesCArrayFlat(KDefaultGranu);
-	iCmManager.OpenL();
+
 	iImageHandler = CImageHandler::NewL(FsSession(), *this);
+
+	TRAPD(err,iCmManager.OpenL());
+	DP1("iCmManager.OpenL(),err=%d;", err);
 	
-	UpdateIAPListL();
-	UpdateSNAPListL();
+	if (err == KErrNone)
+		{
+		UpdateIAPListL();
+		UpdateSNAPListL();
+		}
 	
 	iSettingsEngine = CSettingsEngine::NewL(*this);
 	iConnectionEngine = CConnectionEngine::NewL(*this);	
 	
-	TRAPD(err, OpenDBL());
+	TRAP(err, OpenDBL());
 	
 	if (err != KErrNone)
 		{