clean up the pass/fail logic, still return the same value from test if it fails
diff --git a/tinyxml2.h b/tinyxml2.h
index 72dc801..a4aa6d3 100755
--- a/tinyxml2.h
+++ b/tinyxml2.h
@@ -14,6 +14,7 @@
software in a product, an acknowledgment in the product documentation
would be appreciated but is not required.
+
2. Altered source versions must be plainly marked as such, and
must not be misrepresented as being the original software.
diff --git a/xmltest.cpp b/xmltest.cpp
index 1df0c44..86b4ba2 100644
--- a/xmltest.cpp
+++ b/xmltest.cpp
@@ -21,7 +21,6 @@
#endif
using namespace tinyxml2;
-int gTests = 0;
int gPass = 0;
int gFail = 0;
@@ -48,8 +47,6 @@
}
}
- ++gTests;
-
if ( pass )
++gPass;
else
@@ -71,8 +68,6 @@
else
printf (" %s [%d][%d]\n", testString, static_cast<int>(expected), static_cast<int>(found) );
- ++gTests;
-
if ( pass )
++gPass;
else
@@ -1267,5 +1262,6 @@
#endif
printf ("\nPass %d, Fail %d\n", gPass, gFail);
- return (gTests - gPass);
+
+ return gFail;
}