harvester/monitorplugins/mdsfileserverplugin/src/mdsfileserverplugin.cpp
branchGCC_SURGE
changeset 39 3d9988ee47f5
parent 31 81125601ee77
child 40 910a23996aa0
child 54 a3cc46f37772
equal deleted inserted replaced
32:bf039b7fe409 39:3d9988ee47f5
    19 #include "mdsfileserverplugin.h"
    19 #include "mdsfileserverplugin.h"
    20 #include "harvesterlog.h"
    20 #include "harvesterlog.h"
    21 #include "mdsutils.h"
    21 #include "mdsutils.h"
    22 
    22 
    23 _LIT( KMdsFileServerPlugin, "MdsFileServerPlugin" );
    23 _LIT( KMdsFileServerPlugin, "MdsFileServerPlugin" );
       
    24 _LIT( KExludedThumbPath, "\\_PAlbTN\\");
       
    25 _LIT( KExludedMediaArtPath, "\\.mediaartlocal\\");
    24 
    26 
    25 /* Server name */
    27 /* Server name */
    26 _LIT( KHarvesterServerName, "HarvesterServer" );
    28 _LIT( KHarvesterServerName, "HarvesterServer" );
    27 
    29 
    28 const TInt KCleanQueueTreshold( 1000 );
    30 const TInt KCleanQueueTreshold( 1000 );
    43 //
    45 //
    44 CMdsFileServerPlugin::~CMdsFileServerPlugin()
    46 CMdsFileServerPlugin::~CMdsFileServerPlugin()
    45     {
    47     {
    46     WRITELOG( "CMdsFileServerPlugin::~CMdsFileServerPlugin()" );
    48     WRITELOG( "CMdsFileServerPlugin::~CMdsFileServerPlugin()" );
    47     
    49     
    48     TRAP_IGNORE( DisableL() );
    50 #ifdef _DEBUG
    49     iFsSession.Close();
    51     TRAPD( error, DisableL() );
       
    52     _LIT( KPanicCategory,"CMdsFileServerPlugin" );
       
    53     __ASSERT_DEBUG( error == KErrNone, User::Panic( KPanicCategory,  error ) );
       
    54 #else
       
    55     TRAP_IGNORE( DisableL() );    
       
    56 #endif
    50     
    57     
    51     iCreatedFiles.ResetAndDestroy();
    58     iCreatedFiles.ResetAndDestroy();
    52     iCreatedFiles.Close();
    59     iCreatedFiles.Close();
    53     
    60     
    54     iModifiedFiles.ResetAndDestroy();
    61     iModifiedFiles.ResetAndDestroy();
    79 //-----------------------------------------------------------------------------
    86 //-----------------------------------------------------------------------------
    80 //
    87 //
    81 void CMdsFileServerPlugin::InitialiseL()
    88 void CMdsFileServerPlugin::InitialiseL()
    82     {
    89     {
    83     WRITELOG( "CMdsFileServerPlugin::InitializeL()" );
    90     WRITELOG( "CMdsFileServerPlugin::InitializeL()" );
    84     User::LeaveIfError( iFsSession.Connect() );
       
    85     }
    91     }
    86     
    92     
    87 //-----------------------------------------------------------------------------
    93 //-----------------------------------------------------------------------------
    88 // 
    94 // 
    89 //-----------------------------------------------------------------------------
    95 //-----------------------------------------------------------------------------
   172 // 
   178 // 
   173 //-----------------------------------------------------------------------------
   179 //-----------------------------------------------------------------------------
   174 //
   180 //
   175 TInt CMdsFileServerPlugin::DoRequestL( TFsPluginRequest& aRequest )
   181 TInt CMdsFileServerPlugin::DoRequestL( TFsPluginRequest& aRequest )
   176 	{
   182 	{
   177 	// ignore event if there is no any client listening
   183 	// ignore event if there are not any clients listening
   178 	if( iConnectionCount <= 0 )
   184 	if( iConnectionCount <= 0 )
   179 		{
   185 		{
   180 		WRITELOG( "CMdsFileServerPlugin::DoRequestL() - no clients -> ignore event" );
   186 		WRITELOG( "CMdsFileServerPlugin::DoRequestL() - no clients -> ignore event" );
   181 		return KErrNone;
   187 		return KErrNone;
   182 		}
   188 		}
   199             }
   205             }
   200 #endif
   206 #endif
   201         return KErrNone;
   207         return KErrNone;
   202         }
   208         }
   203     
   209     
   204     const TBool formatFunction = function == EFsFormatOpen || function == EFsFormatSubClose;
   210     const TBool formatFunction( function == EFsFormatOpen || function == EFsFormatSubClose );
   205         
   211         
   206     WRITELOG1( "----- CMdsFileServerPlugin::DoRequestL() - plugin function: %d -----", function );
   212     WRITELOG1( "----- CMdsFileServerPlugin::DoRequestL() - plugin function: %d -----", function );
   207 
   213 
   208 	if ( !formatFunction )
   214 	if ( !formatFunction )
   209 		{
   215 		{
   216 		    WRITELOG1( "CMdsFileServerPlugin::DoRequestL() - fileName: %S", &iFileName );
   222 		    WRITELOG1( "CMdsFileServerPlugin::DoRequestL() - fileName: %S", &iFileName );
   217 		    }
   223 		    }
   218 		}
   224 		}
   219 
   225 
   220     // get process id
   226     // get process id
   221 	TUid processId = { 0 };
   227 	TUid processId = aRequest.Message().SecureId();
   222 
       
   223 	processId = aRequest.Message().SecureId();
       
   224 
   228 
   225 	TBool isDirectory = EFalse;
   229 	TBool isDirectory = EFalse;
   226 	
   230 	
   227     // if rename, check destination path
   231     // if rename, check destination path
   228     if ( function == EFsRename  || function == EFsFileRename || 
   232     if ( function == EFsRename  || function == EFsFileRename || 
   233         if ( iNewFileName.Length() > KMaxFileName )
   237         if ( iNewFileName.Length() > KMaxFileName )
   234         	{
   238         	{
   235         	return KErrNone;
   239         	return KErrNone;
   236         	}
   240         	}
   237         WRITELOG2( "CMdsFileServerPlugin::DoRequestL() - newFileName: '%S' %d", &iNewFileName, newNameErr );
   241         WRITELOG2( "CMdsFileServerPlugin::DoRequestL() - newFileName: '%S' %d", &iNewFileName, newNameErr );
       
   242         TBool setToBeDeleted( EFalse );
   238         if ( newNameErr == KErrNone )
   243         if ( newNameErr == KErrNone )
   239             {
   244             {
   240             if ( !CheckPath(iNewFileName) )
   245             if ( !CheckPath(iNewFileName) )
   241                 {
   246                 {
   242                 WRITELOG( "CMdsFileServerPlugin::DoRequestL() - new path not supported" );
   247                 WRITELOG( "CMdsFileServerPlugin::DoRequestL() - new path not supported" );
   246                     WRITELOG( "CMdsFileServerPlugin::DoRequestL() - ignore file" );
   251                     WRITELOG( "CMdsFileServerPlugin::DoRequestL() - ignore file" );
   247                     return KErrNone;
   252                     return KErrNone;
   248                     }
   253                     }
   249                 // file moved to ignored path, delete from db
   254                 // file moved to ignored path, delete from db
   250                 function = EFsDelete;
   255                 function = EFsDelete;
       
   256                 setToBeDeleted = ETrue;
   251                 }
   257                 }
   252             
   258             
   253             if ( !CheckAttribs( iNewFileName, isDirectory ) )
   259             if( !setToBeDeleted )
   254                 {
   260                 {
   255                 WRITELOG( "CMdsFileServerPlugin::DoRequestL() - new path attribute check failed" );
   261                 RFsPlugin fsPlugin( aRequest ); 
   256                 if( !CheckAttribs(iFileName, isDirectory) )
   262                 const TInt rfsPluginErr = fsPlugin.Connect();
       
   263             
       
   264                 if ( ( rfsPluginErr == KErrNone ) && !CheckAttribs( iNewFileName, isDirectory, fsPlugin, EFalse ) )
   257                     {
   265                     {
   258                     WRITELOG( "CMdsFileServerPlugin::DoRequestL() - old path attribute check failed" );
   266                     WRITELOG( "CMdsFileServerPlugin::DoRequestL() - new path attribute check failed" );
   259                     WRITELOG( "CMdsFileServerPlugin::DoRequestL() - ignore file" );
   267                     if( !CheckAttribs(iFileName, isDirectory, fsPlugin, EFalse) )
   260                     return KErrNone;
   268                         {
       
   269                         WRITELOG( "CMdsFileServerPlugin::DoRequestL() - old path attribute check failed" );
       
   270                         WRITELOG( "CMdsFileServerPlugin::DoRequestL() - ignore file" );
       
   271                         fsPlugin.Close();
       
   272                         return KErrNone;
       
   273                         }
       
   274                     // file set to hidden, delete from db
       
   275                     function = EFsDelete;
   261                     }
   276                     }
   262                 // file set to hidden, delete from db
   277                 fsPlugin.Close();
   263                 function = EFsDelete;
       
   264                 }
   278                 }
   265             }
   279             }
   266         else
   280         else
   267         	{
   281         	{
   268             if ( !CheckPath(iFileName) )
   282             if( !CheckIfValidFile(iFileName, isDirectory, aRequest, EFalse)  )
   269                 {
   283                 {
   270                 WRITELOG( "CMdsFileServerPlugin::DoRequestL() - path not supported" );
       
   271                 return KErrNone;
       
   272                 }
       
   273 
       
   274             if ( !CheckAttribs(iFileName, isDirectory) )
       
   275                 {
       
   276                 WRITELOG( "CMdsFileServerPlugin::DoRequestL() - attribute check failed" );
       
   277                 return KErrNone;
   284                 return KErrNone;
   278                 }
   285                 }
   279         	}
   286         	}
   280         }
   287         }
   281     else if ( !formatFunction )
   288     else if ( !formatFunction )
   282         {
   289         {
   283         if ( !CheckPath(iFileName) )
   290         const TBool deleteFunction( function == EFsDelete );
   284             {
   291         if( !CheckIfValidFile(iFileName, isDirectory, aRequest, deleteFunction)  )
   285             WRITELOG( "CMdsFileServerPlugin::DoRequestL() - path not supported" );
   292             {
   286             return KErrNone;
       
   287             }
       
   288 
       
   289         if ( !CheckAttribs( iFileName, isDirectory ) )
       
   290             {
       
   291             WRITELOG( "CMdsFileServerPlugin::DoRequestL() - attribute check failed" );
       
   292             return KErrNone;
   293             return KErrNone;
   293             }
   294             }
   294         }
   295         }
   295 
   296 
   296     TInt fileEventType = EMdsFileUnknown;
   297     TInt fileEventType = EMdsFileUnknown;
   304     switch( function )
   305     switch( function )
   305         {
   306         {
   306         case EFsFileCreate:
   307         case EFsFileCreate:
   307             {
   308             {
   308 #ifdef _DEBUG            
   309 #ifdef _DEBUG            
   309             if (function == EFsFileCreate)            
   310             if (function == EFsFileCreate)
       
   311                 {
   310             	WRITELOG( "CMdsFileServerPlugin::DoRequestL() - EFsFileCreate" );
   312             	WRITELOG( "CMdsFileServerPlugin::DoRequestL() - EFsFileCreate" );
   311             if (function == EFsFileReplace)
   313                 }
   312             	WRITELOG( "CMdsFileServerPlugin::DoRequestL() - EFsFileReplace" );
       
   313 #endif            
   314 #endif            
   314             
   315             
   315             iCreatedFiles.Append( iFileName.AllocL() );
   316             HBufC* createdFileName = iFileName.Alloc();
   316             User::LeaveIfError( UnregisterIntercept(EFsFileSetModified, EPostIntercept) );
   317             if( createdFileName )
       
   318                 {
       
   319                 // Ownership transferred if succeeded
       
   320                 const TInt appendError( iCreatedFiles.Append( createdFileName ) );
       
   321                 if( appendError != KErrNone )
       
   322                     {
       
   323                     delete createdFileName;
       
   324                     createdFileName = NULL;
       
   325                     }
       
   326                 }
   317             return KErrNone;
   327             return KErrNone;
   318             }
   328             }
   319 
   329 
   320         case EFsFileSubClose:
   330         case EFsFileSubClose:
   321             {
   331             {
   329             		  {
   339             		  {
   330             			fileEventType = EMdsFileCreated;
   340             			fileEventType = EMdsFileCreated;
   331             			delete iCreatedFiles[i];
   341             			delete iCreatedFiles[i];
   332             			iCreatedFiles.Remove( i );
   342             			iCreatedFiles.Remove( i );
   333             			
   343             			
   334 						//Have to check whether file has been hidden
   344 						//Have to check whether file has been hidden          			
   335 						if ( CheckAttribs( iFileName, isDirectory ) )
   345             	        RFsPlugin fsPlugin( aRequest ); 
   336 							{
   346             	        const TInt rfsPluginError( fsPlugin.Connect() );
   337 							found = ETrue;
   347             	        if( (rfsPluginError == KErrNone) && CheckAttribs( iFileName, isDirectory, fsPlugin, EFalse ) )
   338 							}
   348             	            {
   339     						
   349             	            found = ETrue;
   340             			User::LeaveIfError( RegisterIntercept(EFsFileSetModified, EPostIntercept) );
   350             	            }
       
   351             	        else if( rfsPluginError != KErrNone )
       
   352             	            {
       
   353             	            found = ETrue;
       
   354             	            }
       
   355             	        fsPlugin.Close();
   341             			}
   356             			}
   342             		}
   357             		}
   343            	
   358            	
   344            	if( iCreatedFiles.Count() == 0 )
   359            	if( iCreatedFiles.Count() == 0 )
   345 				{
   360 				{
   375             WRITELOG1( "CMdsFileServerPlugin::DoRequestL() - EFsFileRename, new file: %S", &iNewFileName );
   390             WRITELOG1( "CMdsFileServerPlugin::DoRequestL() - EFsFileRename, new file: %S", &iNewFileName );
   376             fileEventType = EMdsFileRenamed;
   391             fileEventType = EMdsFileRenamed;
   377             break;
   392             break;
   378 
   393 
   379         case EFsFileSetModified:
   394         case EFsFileSetModified:
   380         
   395             {
   381             WRITELOG( "CMdsFileServerPlugin::DoRequestL() - EFsFileSetModified" );
   396             WRITELOG( "CMdsFileServerPlugin::DoRequestL() - EFsFileSetModified" );
   382             iModifiedFiles.Append( iFileName.AllocL() );
   397             
       
   398             for ( TInt i = iCreatedFiles.Count(); --i >= 0; )
       
   399                 {
       
   400                 // If file has been created but not closed, do not handle modified events
       
   401                 // for that file before the application that has created the file is done with writing 
       
   402                 // it to the disk.
       
   403                 if ( MdsUtils::Compare( iFileName, *(iCreatedFiles[i]) ) == 0 )
       
   404                     {
       
   405                     return KErrNone;
       
   406                     }
       
   407                 } 
       
   408 
       
   409             HBufC* modifiedFileName = iFileName.Alloc();
       
   410             if( modifiedFileName )
       
   411                 {
       
   412                 // Ownership transferred if succeeded
       
   413                 const TInt appendError( iModifiedFiles.Append( modifiedFileName ) );
       
   414                 if( appendError != KErrNone )
       
   415                     {
       
   416                     delete modifiedFileName;
       
   417                     modifiedFileName = NULL;
       
   418                     }
       
   419                 }
       
   420             
   383             fileEventType = EMdsFileModified;
   421             fileEventType = EMdsFileModified;
       
   422             }
   384             break;
   423             break;
   385 
   424 
   386         case EFsSetEntry:
   425         case EFsSetEntry:
   387             {
   426             {
   388             WRITELOG( "CMdsFileServerPlugin::DoRequestL() - EFsSetEntry" );
   427             WRITELOG( "CMdsFileServerPlugin::DoRequestL() - EFsSetEntry" );
   426 
   465 
   427 		case EFsFormatOpen:
   466 		case EFsFormatOpen:
   428 		    {
   467 		    {
   429 			WRITELOG( "CMdsFileServerPlugin::DoRequestL() - EFsFormatOpen" );
   468 			WRITELOG( "CMdsFileServerPlugin::DoRequestL() - EFsFormatOpen" );
   430 			// get the drive letter
   469 			// get the drive letter
   431 		    RFsPlugin fsplugin( aRequest ); 
   470 		    RFsPlugin fsPlugin( aRequest ); 
   432 	        const TInt rfsPluginError( fsplugin.Connect() );
   471 		    err = fsPlugin.Connect();
   433 	        if( rfsPluginError == KErrNone )
   472 	        if( err == KErrNone )
   434 	            {
   473 	            {
   435 	            err = fsplugin.Volume( volInfo, drvNumber );
   474 	            err = fsPlugin.Volume( volInfo, drvNumber );
   436 	            }
   475 	            }
   437 	        else
   476 	        fsPlugin.Close();
   438 	            {
       
   439 	            err = iFsSession.Volume( volInfo, drvNumber );
       
   440 	            }
       
   441 	        fsplugin.Close();
       
   442 	        
   477 	        
   443 			if( KErrNone == err )
   478 			if( KErrNone == err )
   444 				{
   479 				{
   445 				iFormatOldMediaId = volInfo.iUniqueID;
   480 				iFormatOldMediaId = volInfo.iUniqueID;
   446 				iFormatDriveNumber = drvNumber;
   481 				iFormatDriveNumber = drvNumber;
   778 
   813 
   779         WRITELOG1( "CMdsFileServerPlugin::AddNotificationPath() - add path: %S", &status.iFileName );
   814         WRITELOG1( "CMdsFileServerPlugin::AddNotificationPath() - add path: %S", &status.iFileName );
   780         HBufC* fn = status.iFileName.Alloc();
   815         HBufC* fn = status.iFileName.Alloc();
   781         if ( fn )
   816         if ( fn )
   782             {
   817             {
   783             iPaths.InsertInOrder(fn, TLinearOrder<TDesC>(CMdsFileServerPlugin::Compare)); 
   818             const TInt insertError( iPaths.InsertInOrder(fn, TLinearOrder<TDesC>(CMdsFileServerPlugin::Compare)));
       
   819             if( insertError != KErrNone )
       
   820                 {
       
   821                 delete fn;
       
   822                 fn = NULL;
       
   823                 }
   784             }
   824             }
   785         else
   825         else
   786             {
   826             {
   787             err = KErrNoMemory;
   827             err = KErrNoMemory;
   788             }
   828             }
   868             
   908             
   869         WRITELOG1( "CMdsFileServerPlugin::AddIgnorePath() - add path: %S", &status.iFileName );
   909         WRITELOG1( "CMdsFileServerPlugin::AddIgnorePath() - add path: %S", &status.iFileName );
   870         HBufC* fn = status.iFileName.Alloc();
   910         HBufC* fn = status.iFileName.Alloc();
   871         if ( fn )
   911         if ( fn )
   872             {
   912             {
   873             iIgnorePaths.InsertInOrder(fn, TLinearOrder<TDesC>(CMdsFileServerPlugin::Compare)); 
   913             const TInt insertError( iIgnorePaths.InsertInOrder(fn, TLinearOrder<TDesC>(CMdsFileServerPlugin::Compare))); 
       
   914             if( insertError != KErrNone )
       
   915                 {
       
   916                 delete fn;
       
   917                 fn = NULL;
       
   918                 }
   874             }
   919             }
   875         else
   920         else
   876             {
   921             {
   877             err = KErrNoMemory;
   922             err = KErrNoMemory;
   878             }
   923             }
   945         TDesC* pathName = iIgnorePaths[i];
   990         TDesC* pathName = iIgnorePaths[i];
   946         if ( MdsUtils::Find( aFilename, *pathName ) != KErrNotFound )
   991         if ( MdsUtils::Find( aFilename, *pathName ) != KErrNotFound )
   947             {
   992             {
   948             return EFalse;
   993             return EFalse;
   949             }
   994             }
       
   995         else if( MdsUtils::Find( aFilename, KExludedThumbPath ) != KErrNotFound )
       
   996             {
       
   997             return EFalse;
       
   998             }
       
   999         else if( MdsUtils::Find( aFilename, KExludedMediaArtPath ) != KErrNotFound )
       
  1000             {
       
  1001             return EFalse;
       
  1002             }
   950         }
  1003         }
   951 
  1004 
   952     // check if notification path
  1005     // check if notification path
   953     if ( iPaths.Count() > 0 )
  1006     if ( iPaths.Count() > 0 )
   954         {
  1007         {
   979 //-----------------------------------------------------------------------------
  1032 //-----------------------------------------------------------------------------
   980 // CheckAttribs
  1033 // CheckAttribs
   981 //-----------------------------------------------------------------------------
  1034 //-----------------------------------------------------------------------------
   982 //
  1035 //
   983 TBool CMdsFileServerPlugin::CheckAttribs( const TDesC& aFilename, 
  1036 TBool CMdsFileServerPlugin::CheckAttribs( const TDesC& aFilename, 
   984 		TBool& aIsDirectory ) const
  1037 		TBool& aIsDirectory, RFsPlugin& aFsPlugin, TBool aDelete ) const
   985 	{
  1038 	{
   986 	// find last backslash from filename and 
  1039 	// find last backslash from filename and 
   987     // take drive and path from filename including last backslash
  1040     // take drive and path from filename including last backslash
   988     const TChar KBackslashChar( '\\' );
  1041     const TChar KBackslashChar( '\\' );
   989     TInt pos = aFilename.LocateReverse( KBackslashChar );
  1042     TInt pos = aFilename.LocateReverse( KBackslashChar );
   991     	{
  1044     	{
   992     	return ETrue;
  1045     	return ETrue;
   993     	}
  1046     	}
   994     TPtrC path( aFilename.Left( pos + 1 ) );
  1047     TPtrC path( aFilename.Left( pos + 1 ) );
   995 
  1048 
   996     TUint att = 0;
  1049     TEntry entry;
   997 
  1050 
   998     // check if path is hidden or system path
  1051     // check if path is hidden 
   999     TInt err = iFsSession.Att( path, att );
  1052     TInt err = aFsPlugin.Entry( path, entry );
  1000     if ( err == KErrNone )
  1053     if ( err == KErrNone )
  1001         {
  1054         {      
  1002         if ( att & KEntryAttHidden || att & KEntryAttSystem )
  1055         if ( entry.iAtt & KEntryAttHidden )
  1003             {
  1056             {
  1004             return EFalse;
  1057             return EFalse;
  1005             }
  1058             }
  1006         }
  1059         }
  1007 
  1060 
  1008     // or is the file hidden or system file
  1061     if( !aDelete )
  1009     att = 0;
  1062         {
  1010     err = iFsSession.Att( aFilename, att );
  1063         // check if the file hidden or system file
  1011     if ( err == KErrNone )
  1064         err = aFsPlugin.Entry( aFilename, entry );
  1012         {
  1065         if ( err == KErrNone )
  1013         if ( att & KEntryAttHidden || att & KEntryAttSystem )
  1066             {
  1014             {
  1067             if ( entry.iAtt & KEntryAttHidden || entry.iAtt & KEntryAttSystem )
  1015             return EFalse;
  1068                 {
  1016             }
  1069                 return EFalse;
       
  1070                 }
  1017         
  1071         
  1018         aIsDirectory = att & KEntryAttDir ? ETrue : EFalse;
  1072             aIsDirectory = entry.iAtt & KEntryAttDir ? ETrue : EFalse;
       
  1073             }    
  1019         }
  1074         }
  1020 
  1075 
  1021     return ETrue;
  1076     return ETrue;
  1022     }
  1077     }
  1023 
  1078 
  1069         return ETrue;
  1124         return ETrue;
  1070         }
  1125         }
  1071     
  1126     
  1072     WRITELOG( "CMdsFileServerPlugin::CheckHarvesterStatus() - end" );
  1127     WRITELOG( "CMdsFileServerPlugin::CheckHarvesterStatus() - end" );
  1073     return EFalse;
  1128     return EFalse;
       
  1129     }
       
  1130 
       
  1131 //-----------------------------------------------------------------------------
       
  1132 // CheckIfValidFile
       
  1133 //-----------------------------------------------------------------------------
       
  1134 //
       
  1135 TBool CMdsFileServerPlugin::CheckIfValidFile( const TDesC& aFilename, 
       
  1136         TBool& aIsDirectory, TFsPluginRequest& aRequest, TBool aDelete )
       
  1137     {
       
  1138     if ( !CheckPath(aFilename) )
       
  1139         {
       
  1140         WRITELOG( "CMdsFileServerPlugin::CheckIfValidFile() - path not supported" );
       
  1141         return EFalse;
       
  1142         }
       
  1143 
       
  1144     RFsPlugin fsPlugin( aRequest ); 
       
  1145     const TInt rfsPluginErr = fsPlugin.Connect();
       
  1146     
       
  1147     if( rfsPluginErr == KErrNone )
       
  1148         {
       
  1149         if ( !CheckAttribs(aFilename, aIsDirectory, fsPlugin, aDelete) )
       
  1150             {
       
  1151             WRITELOG( "CMdsFileServerPlugin::CheckIfValidFile() - attribute check failed" );
       
  1152             return EFalse;
       
  1153             }
       
  1154         }
       
  1155     fsPlugin.Close(); 
       
  1156     
       
  1157     return ETrue;
  1074     }
  1158     }
  1075 
  1159 
  1076 //-----------------------------------------------------------------------------
  1160 //-----------------------------------------------------------------------------
  1077 // CMdsFileServerPluginFactory implementation
  1161 // CMdsFileServerPluginFactory implementation
  1078 //-----------------------------------------------------------------------------
  1162 //-----------------------------------------------------------------------------