Merge branch 'master' of github.com:leethomason/tinyxml2

This commit is contained in:
Lee Thomason (grinliz) 2012-09-23 20:26:12 -07:00
commit 99024dc20b
2 changed files with 7 additions and 42 deletions

View File

@ -85,7 +85,7 @@
</PrecompiledHeader> </PrecompiledHeader>
<WarningLevel>Level4</WarningLevel> <WarningLevel>Level4</WarningLevel>
<Optimization>Disabled</Optimization> <Optimization>Disabled</Optimization>
<PreprocessorDefinitions>WIN32;_DEBUG;_CONSOLE;%(PreprocessorDefinitions)</PreprocessorDefinitions> <PreprocessorDefinitions>;_CONSOLE;WIN32;_DEBUG;%(PreprocessorDefinitions)</PreprocessorDefinitions>
<ExceptionHandling>false</ExceptionHandling> <ExceptionHandling>false</ExceptionHandling>
</ClCompile> </ClCompile>
<Link> <Link>
@ -115,7 +115,7 @@
<Optimization>MaxSpeed</Optimization> <Optimization>MaxSpeed</Optimization>
<FunctionLevelLinking>true</FunctionLevelLinking> <FunctionLevelLinking>true</FunctionLevelLinking>
<IntrinsicFunctions>true</IntrinsicFunctions> <IntrinsicFunctions>true</IntrinsicFunctions>
<PreprocessorDefinitions>WIN32;NDEBUG;_CONSOLE;%(PreprocessorDefinitions)</PreprocessorDefinitions> <PreprocessorDefinitions>WIN32;NDEBUG;_CONSOLE;_CRT_SECURE_NO_WARNINGS;%(PreprocessorDefinitions)</PreprocessorDefinitions>
<StringPooling>true</StringPooling> <StringPooling>true</StringPooling>
</ClCompile> </ClCompile>
<Link> <Link>
@ -145,7 +145,9 @@
</ItemDefinitionGroup> </ItemDefinitionGroup>
<ItemGroup> <ItemGroup>
<ClCompile Include="..\tinyxml2.cpp" /> <ClCompile Include="..\tinyxml2.cpp" />
<ClCompile Include="..\xmltest.cpp" /> <ClCompile Include="..\xmltest.cpp">
<PreprocessorDefinitions Condition="'$(Configuration)|$(Platform)'=='Debug|Win32'">_CRT_SECURE_NO_WARNINGS;_CONSOLE;WIN32;_DEBUG;%(PreprocessorDefinitions)</PreprocessorDefinitions>
</ClCompile>
</ItemGroup> </ItemGroup>
<ItemGroup> <ItemGroup>
<ClInclude Include="..\tinyxml2.h" /> <ClInclude Include="..\tinyxml2.h" />

View File

@ -153,11 +153,6 @@ int main( int /*argc*/, const char ** /*argv*/ )
_CrtMemCheckpoint( &startMemState ); _CrtMemCheckpoint( &startMemState );
#endif #endif
#if defined(_MSC_VER)
#pragma warning ( push )
#pragma warning ( disable : 4996 ) // Fail to see a compelling reason why this should be deprecated.
#endif
#if defined(_MSC_VER) #if defined(_MSC_VER)
_mkdir( "resources/out/" ); _mkdir( "resources/out/" );
#else #else
@ -178,10 +173,6 @@ int main( int /*argc*/, const char ** /*argv*/ )
} }
fclose( fp ); fclose( fp );
#if defined(_MSC_VER)
#pragma warning ( pop )
#endif
XMLTest( "Example-1", 0, example_1() ); XMLTest( "Example-1", 0, example_1() );
XMLTest( "Example-2", 0, example_2() ); XMLTest( "Example-2", 0, example_2() );
XMLTest( "Example-3", 0, example_3() ); XMLTest( "Example-3", 0, example_3() );
@ -424,16 +415,8 @@ int main( int /*argc*/, const char ** /*argv*/ )
// Check the round trip. // Check the round trip.
int okay = 0; int okay = 0;
#if defined(_MSC_VER)
#pragma warning ( push )
#pragma warning ( disable : 4996 ) // Fail to see a compelling reason why this should be deprecated.
#endif
FILE* saved = fopen( "resources/out/utf8testout.xml", "r" ); FILE* saved = fopen( "resources/out/utf8testout.xml", "r" );
FILE* verify = fopen( "resources/utf8testverify.xml", "r" ); FILE* verify = fopen( "resources/utf8testverify.xml", "r" );
#if defined(_MSC_VER)
#pragma warning ( pop )
#endif
if ( saved && verify ) if ( saved && verify )
{ {
@ -548,28 +531,15 @@ int main( int /*argc*/, const char ** /*argv*/ )
XMLTest( "Entity transformation: read. ", expected, context, true ); XMLTest( "Entity transformation: read. ", expected, context, true );
#if defined(_MSC_VER)
#pragma warning ( push )
#pragma warning ( disable : 4996 ) // Fail to see a compelling reason why this should be deprecated.
#endif
FILE* textfile = fopen( "resources/out/textfile.txt", "w" ); FILE* textfile = fopen( "resources/out/textfile.txt", "w" );
#if defined(_MSC_VER)
#pragma warning ( pop )
#endif
if ( textfile ) if ( textfile )
{ {
XMLPrinter streamer( textfile ); XMLPrinter streamer( textfile );
psg->Accept( &streamer ); psg->Accept( &streamer );
fclose( textfile ); fclose( textfile );
} }
#if defined(_MSC_VER)
#pragma warning ( push )
#pragma warning ( disable : 4996 ) // Fail to see a compelling reason why this should be deprecated.
#endif
textfile = fopen( "resources/out/textfile.txt", "r" ); textfile = fopen( "resources/out/textfile.txt", "r" );
#if defined(_MSC_VER)
#pragma warning ( pop )
#endif
TIXMLASSERT( textfile ); TIXMLASSERT( textfile );
if ( textfile ) if ( textfile )
{ {
@ -999,14 +969,7 @@ int main( int /*argc*/, const char ** /*argv*/ )
QueryPerformanceFrequency( (LARGE_INTEGER*) &freq ); QueryPerformanceFrequency( (LARGE_INTEGER*) &freq );
#endif #endif
#if defined(_MSC_VER)
#pragma warning ( push )
#pragma warning ( disable : 4996 ) // Fail to see a compelling reason why this should be deprecated.
#endif
FILE* fp = fopen( "resources/dream.xml", "r" ); FILE* fp = fopen( "resources/dream.xml", "r" );
#if defined(_MSC_VER)
#pragma warning ( pop )
#endif
fseek( fp, 0, SEEK_END ); fseek( fp, 0, SEEK_END );
long size = ftell( fp ); long size = ftell( fp );
fseek( fp, 0, SEEK_SET ); fseek( fp, 0, SEEK_SET );