loggingservices/eventlogger/test/src/t_loghicaphelper.cpp
changeset 22 a7ba600cb39d
parent 17 55f2396f6d25
child 25 63532cdadd44
equal deleted inserted replaced
19:d6ef85bc5971 22:a7ba600cb39d
   147    	CleanupStack::PushL(backup);
   147    	CleanupStack::PushL(backup);
   148    
   148    
   149    	//This eventually calls CLogBackup::ChangeFileLockL(..) which closes the database 
   149    	//This eventually calls CLogBackup::ChangeFileLockL(..) which closes the database 
   150    	//file and notifies all handles to that file that it has closed.
   150    	//file and notifies all handles to that file that it has closed.
   151    	backup->CloseFileL(KLogDatabaseName, MBackupObserver::EReleaseLockNoAccess);
   151    	backup->CloseFileL(KLogDatabaseName, MBackupObserver::EReleaseLockNoAccess);
   152  	User::After(1000000);
   152  	User::After(300000);
   153    	
   153    	
   154    	//Since the log engine database file is closed we can replace it.   
   154    	//Since the log engine database file is closed we can replace it.   
   155    	//Once this file is deleted, the backup server notices this and attempts to reopen 
   155    	//Once this file is deleted, the backup server notices this and attempts to reopen 
   156    	//the database.  Since the file is deleted a default database is created instead.
   156    	//the database.  Since the file is deleted a default database is created instead.
   157     RDbNamedDatabase database;
   157     RDbNamedDatabase database;
   385         CleanupStack::PushL(backup);
   385         CleanupStack::PushL(backup);
   386 
   386 
   387         //This eventually calls CLogBackup::ChangeFileLockL(..) which closes the database 
   387         //This eventually calls CLogBackup::ChangeFileLockL(..) which closes the database 
   388         //file and notifies all handles to that file that it has closed.
   388         //file and notifies all handles to that file that it has closed.
   389         backup->CloseFileL(aDbPath, MBackupObserver::EReleaseLockNoAccess);
   389         backup->CloseFileL(aDbPath, MBackupObserver::EReleaseLockNoAccess);
   390         User::After(1000000);
   390         User::After(300000);
   391         }
   391         }
   392 
   392 
   393     //Since the log engine database file is closed we can delete it.   
   393     //Since the log engine database file is closed we can delete it.   
   394     //Once this file is deleted, the backup server notices this and attempts to reopen 
   394     //Once this file is deleted, the backup server notices this and attempts to reopen 
   395     //the database.  Since the file is deleted a default database is created instead.
   395     //the database.  Since the file is deleted a default database is created instead.