summaryrefslogtreecommitdiff
path: root/ACEXML
diff options
context:
space:
mode:
authormichel_j <michel_j@ae88bc3d-4319-0410-8dbf-d08b4c9d3795>2005-05-24 14:39:07 +0000
committermichel_j <michel_j@ae88bc3d-4319-0410-8dbf-d08b4c9d3795>2005-05-24 14:39:07 +0000
commit503e71fb3a9f52588308ecd0cbd0b864986bf409 (patch)
tree3f3f28534a7f993fbfa9979be2d6b0b18c831b1c /ACEXML
parent8ca914c2e8df976876896fe90e5be77973378638 (diff)
downloadATCD-503e71fb3a9f52588308ecd0cbd0b864986bf409.tar.gz
ChangeLogTag: Tue May 24 09:18:34 2005 Justin Michel <michel_j@ociweb.com>
Diffstat (limited to 'ACEXML')
-rw-r--r--ACEXML/tests/util/test.cpp9
1 files changed, 5 insertions, 4 deletions
diff --git a/ACEXML/tests/util/test.cpp b/ACEXML/tests/util/test.cpp
index 8ed59accc59..40f0eb41001 100644
--- a/ACEXML/tests/util/test.cpp
+++ b/ACEXML/tests/util/test.cpp
@@ -24,7 +24,8 @@ static int run_tests(ACEXML_String test_strings[NUM_TEST_STRS], int iterations)
{
// Test 1 - Escape the strings using a new temporary string each iteration.
ACE_Time_Value start = ACE_OS::gettimeofday();
- for (int i = 0; i < iterations; ++i)
+ int i = 0;
+ for (i = 0; i < iterations; ++i)
{
ACEXML_String tmp = ACEXML_escape_string(test_strings[i % NUM_TEST_STRS]);
if (! is_escaped(tmp))
@@ -39,7 +40,7 @@ static int run_tests(ACEXML_String test_strings[NUM_TEST_STRS], int iterations)
// be any faster than Test 1 as long as the compiler has return value optimization.
ACEXML_String tmp;
start = ACE_OS::gettimeofday();
- for (int i = 0; i < iterations; ++i)
+ for (i = 0; i < iterations; ++i)
{
tmp = ACEXML_escape_string(test_strings[i % NUM_TEST_STRS]);
if (! is_escaped(tmp))
@@ -54,7 +55,7 @@ static int run_tests(ACEXML_String test_strings[NUM_TEST_STRS], int iterations)
// the alternate form of ACEXML_escape_string() so that our temporary buffer is reused.
tmp.clear(1);
start = ACE_OS::gettimeofday();
- for (int i = 0; i < iterations; ++i)
+ for (i = 0; i < iterations; ++i)
{
ACEXML_escape_string(test_strings[i % NUM_TEST_STRS], tmp);
if (! is_escaped(tmp))
@@ -67,7 +68,7 @@ static int run_tests(ACEXML_String test_strings[NUM_TEST_STRS], int iterations)
// Test 4 - Same as Test 3, except that the tmp buffer shouldn't have to resize.
start = ACE_OS::gettimeofday();
- for (int i = 0; i < iterations; ++i)
+ for (i = 0; i < iterations; ++i)
{
ACEXML_escape_string(test_strings[i % NUM_TEST_STRS], tmp);
if (! is_escaped(tmp))