--- a/analyzetool/dynamicmemoryhook/src/analyzetooleventhandler.cpp Wed Sep 15 00:19:18 2010 +0300
+++ b/analyzetool/dynamicmemoryhook/src/analyzetooleventhandler.cpp Wed Sep 15 13:53:27 2010 +0300
@@ -68,15 +68,13 @@
iLibraryInfo.iRunAddress,
iLibraryInfo.iRunAddress + iLibraryInfo.iSize );
}
- else
- {
- LOGSTR1( "ATMH CLibraryEventHandler::RunL() - iStorageServer.LogDllLoaded() " );
- error = iStorageServer.LogDllLoaded(
- iLibraryInfo.iLibraryName,
- iLibraryInfo.iRunAddress,
- iLibraryInfo.iRunAddress + iLibraryInfo.iSize );
- LOGSTR2( "ATMH StorageServer error: %i", error );
- }
+ else if( iLogOption == EATLogToFile )
+ {
+ iLogFile.ATFileLogDllLoaded( iLibraryInfo.iLibraryName,
+ iLibraryInfo.iRunAddress,
+ iLibraryInfo.iRunAddress + iLibraryInfo.iSize );
+ }
+
if ( KErrNone == error )
{
iCodeblocks.Append( TCodeblock( iLibraryInfo.iRunAddress,
@@ -106,23 +104,12 @@
iLibraryInfo.iRunAddress,
iLibraryInfo.iRunAddress + iLibraryInfo.iSize );
}
- else
- {
- LOGSTR1( "ATMH CLibraryEventHandler::RunL() - iStorageServer.LogDllUnloaded() " );
- #ifdef LOGGING_ENABLED
- TInt error = iStorageServer.LogDllUnloaded(
- libraryName/*iLibraryInfo.iLibraryName*/,
- iLibraryInfo.iRunAddress,
- iLibraryInfo.iRunAddress + iLibraryInfo.iSize );
-
- LOGSTR2( "ATMH StorageServer error: %i", error );
- #else
- iStorageServer.LogDllUnloaded(
- libraryName/*iLibraryInfo.iLibraryName*/,
- iLibraryInfo.iRunAddress,
- iLibraryInfo.iRunAddress + iLibraryInfo.iSize );
- #endif
- }
+ else if( iLogOption == EATLogToFile )
+ {
+ iLogFile.ATFileLogDllUnloaded( iLibraryInfo.iLibraryName,
+ iLibraryInfo.iRunAddress,
+ iLibraryInfo.iRunAddress + iLibraryInfo.iSize );
+ }
iCodeblocks.Remove( i );
break;
}
@@ -198,19 +185,20 @@
// -----------------------------------------------------------------------------
//
CLibraryEventHandler::CLibraryEventHandler( RAnalyzeTool& aAnalyzeTool,
- RArray<TCodeblock>& aCodeblocks, RATStorageServer& aStorageServer,
+ RArray<TCodeblock>& aCodeblocks,
TUint aProcessId, RMutex& aMutex,
MAnalyzeToolEventhandlerNotifier& aNotifier,
- TUint32 aLogOption )
+ TUint32 aLogOption,
+ RATFileLog& aFileLog )
: CActive( EPriorityNormal ),
iAnalyzeTool( aAnalyzeTool ),
iCodeblocks( aCodeblocks ),
- iStorageServer( aStorageServer ),
iProcessId( aProcessId ),
iMutex( aMutex ),
iStarted( EFalse ),
iNotifier( aNotifier ),
- iLogOption( aLogOption )
+ iLogOption( aLogOption ),
+ iLogFile( aFileLog )
{
LOGSTR1( "ATMH CLibraryEventHandler::CLibraryEventHandler()" );
}