summaryrefslogtreecommitdiff
path: root/cpp
diff options
context:
space:
mode:
authorBernard Normier <bernard@zeroc.com>2007-07-18 11:45:17 -0400
committerBernard Normier <bernard@zeroc.com>2007-07-18 11:45:17 -0400
commitaa839581aa09b4248d32a6444c2d1e1562131dc1 (patch)
treecc5c8b09f93ebf55d9f7b6b0f36acac76803e0ba /cpp
parentBuild fix (diff)
downloadice-aa839581aa09b4248d32a6444c2d1e1562131dc1.tar.bz2
ice-aa839581aa09b4248d32a6444c2d1e1562131dc1.tar.xz
ice-aa839581aa09b4248d32a6444c2d1e1562131dc1.zip
Cleanup
Diffstat (limited to 'cpp')
-rw-r--r--cpp/test/Ice/stringConverter/Client.cpp18
1 files changed, 10 insertions, 8 deletions
diff --git a/cpp/test/Ice/stringConverter/Client.cpp b/cpp/test/Ice/stringConverter/Client.cpp
index bac0a184aac..68f169014ae 100644
--- a/cpp/test/Ice/stringConverter/Client.cpp
+++ b/cpp/test/Ice/stringConverter/Client.cpp
@@ -48,6 +48,8 @@ public:
}
};
+static bool useLocale = false;
+
int
main(int argc, char* argv[])
{
@@ -58,16 +60,11 @@ main(int argc, char* argv[])
// (we just used the codeset for as default internal code for
// initData.stringConverter below)
//
- bool useLocale = false;
+
#ifndef _WIN32
useLocale = (setlocale(LC_ALL, "fr_FR.ISO8859-15") != 0);
#endif
-
- if(useLocale)
- {
- cout << "using locale..." << flush;
- }
-
+
Ice::InitializationData initData;
#if defined(__hpux)
@@ -132,7 +129,12 @@ Client::run(int, char*[])
char oe = char(0xBD); // A single character in ISO Latin 9
string msg = string("tu me fends le c") + oe + "ur!";
- cout << "testing iconv string converter..." << flush;
+ cout << "testing iconv string converter";
+ if(useLocale)
+ {
+ cout << " (using locale)";
+ }
+ cout << "..." << flush;
wstring wmsg = clientPrx->widen(msg);
test(clientPrx->narrow(wmsg) == msg);
test(wmsg.size() == msg.size());