engine/src/PodcastModel.cpp
branchsymbian1
changeset 336 3d6c1417e8bd
parent 211 aa8e7de6f033
child 347 b8d687bb7ca1
--- a/engine/src/PodcastModel.cpp	Tue Oct 26 15:58:11 2010 +0100
+++ b/engine/src/PodcastModel.cpp	Fri Nov 12 20:48:14 2010 +0000
@@ -16,9 +16,6 @@
 *
 */
 
-// when enabled this macro copies the database to c:\data on launch for debug purposes
-//#define COPY_DB
-
 #include <commdb.h>
 #include "PodcastModel.h"
 #include "FeedEngine.h"
@@ -318,7 +315,14 @@
 	dbTemplate.Copy(iSettingsEngine->PrivatePath());
 	dbTemplate.Append(KDBTemplateFileName);
 
+	DP1("Copy template DB from: %S", &dbTemplate);
+	DP1("Copy template DB to: %S", &dbFileName);
+	
 	BaflUtils::CopyFile(iFsSession, dbTemplate,dbFileName);
+	
+	// important to set this file to not be read only if copying from Z:
+	iFsSession.SetAtt(dbFileName, 0, KEntryAttReadOnly); 
+	
 	iIsFirstStartup = ETrue;
 	DP("CPodcastModel::ResetDB END");
 	}