lowlevellibsandfws/pluginfw/Framework/EcomTestUtils/t_processrfsdeletefile.cpp
changeset 44 97b0fb8a2cc2
parent 0 e4d67989cc36
child 57 2efc27d87e1c
equal deleted inserted replaced
22:ddc455616bd6 44:97b0fb8a2cc2
    20 #include <e32debug.h>
    20 #include <e32debug.h>
    21 #include <bautils.h>
    21 #include <bautils.h>
    22 	
    22 	
    23 TInt DoDeleteFileL(const TDesC& aFile)
    23 TInt DoDeleteFileL(const TDesC& aFile)
    24 	{
    24 	{
       
    25 	TInt r = KErrNone;
    25 	RFs fs;
    26 	RFs fs;
    26 	fs.Connect();
    27 	r = fs.Connect();
       
    28 	if (r != KErrNone)
       
    29 		{
       
    30 			User::Leave(r);
       
    31 		}
    27 	
    32 	
    28     // Make the file writeable 
    33     // Make the file writeable 
    29     fs.SetAtt(aFile, 0, KEntryAttReadOnly);
    34     fs.SetAtt(aFile, 0, KEntryAttReadOnly);
    30 	// Delete file using RFs
    35 	// Delete file using RFs
    31 	TInt err = fs.Delete(aFile);
    36 	TInt err = fs.Delete(aFile);