diff --git a/TestEGk.cpp b/TestEGk.cpp index 8e3dce1..0239f2f 100644 --- a/TestEGk.cpp +++ b/TestEGk.cpp @@ -52,39 +52,36 @@ using namespace egtlogger ; int wmain( int argc, wchar_t* argv[]) { - int nErr ; - int nDebug ; - string sIn ; - string sExeDir ; - string sFileIni ; - - // se debug, imposto stampe memory leaks all'uscita #ifdef _DEBUG _CrtSetDbgFlag( _CRTDBG_ALLOC_MEM_DF | _CRTDBG_LEAK_CHECK_DF) ; #endif // recupero il direttorio del programma e costruisco path file INI + string sExeDir ; GetModuleDirectory( NULL, sExeDir) ; - sFileIni = sExeDir + "\\TestEgk.ini" ; + string sFileIni = sExeDir + "\\TestEgk.ini" ; // imposto direttorio di lavoro SetCurrentDirectory( sExeDir) ; - // interpreto i parametri di linea - // nome file di comandi + // nome file di comandi + string sIn ; if ( argc >= 2) sIn = LPSTR( WtoA( argv[1])) ; else sIn = GetPrivateProfileStringUtf8( "General", "Batch", "In.btsc", sFileIni.c_str()) ; - // livello di debug - nDebug = GetPrivateProfileInt( "General", "Debug", 0, sFileIni.c_str()) ; + // livello di debug + int nDebug = GetPrivateProfileInt( "General", "Debug", 0, sFileIni.c_str()) ; + + // file di log + string sLog = GetPrivateProfileStringUtf8( "General", "Log", "TestEgk.log", sFileIni.c_str()) ; // inizializzazioni del logger Logger logger( ( nDebug > 0 ? LL_DEBUG : LL_INFO), "TestEGk") ; logger.AddOutputStream( cout, false, LL_INFO) ; - logger.AddOutputStream( new(nothrow) ofstream( "TestEgk.log"), true) ; + logger.AddOutputStream( new(nothrow) ofstream( sLog), true) ; // inizio programma LOG_DATETIME( &logger, " Start Test") @@ -117,7 +114,7 @@ wmain( int argc, wchar_t* argv[]) InitFontManager( sNfeFontDir, sDefaultFont) ; // nessun errore - nErr = 0 ; + int nErr = 0 ; // esecuzione script PtrOwner pGdb( CreateGeomDB()) ; diff --git a/TestEGk.rc b/TestEGk.rc index a35693a..355ce6a 100644 Binary files a/TestEGk.rc and b/TestEGk.rc differ diff --git a/TestEGk.vcxproj b/TestEGk.vcxproj index 8e2a513..0f5b7a4 100644 --- a/TestEGk.vcxproj +++ b/TestEGk.vcxproj @@ -1,5 +1,5 @@  - + Debug @@ -28,23 +28,27 @@ Application true Unicode + v120_xp Application true Unicode + v120_xp Application false true Unicode + v120_xp Application false true Unicode + v120_xp @@ -161,7 +165,7 @@ true WIN32;NDEBUG;_CONSOLE;%(PreprocessorDefinitions) true - StreamingSIMDExtensions2 + NotSet AnySuitable Speed false