summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorsma <sma@ae88bc3d-4319-0410-8dbf-d08b4c9d3795>2008-06-25 13:56:32 +0000
committersma <sma@ae88bc3d-4319-0410-8dbf-d08b4c9d3795>2008-06-25 13:56:32 +0000
commit0741d5a101d356bdad118fdcce07dac03f4ae7f3 (patch)
tree677f4b71a31e2b5ca18e527aa2fdfa1853daa5cd
parentecc8bc5a79109011607ac4f930b1b447aa51b053 (diff)
downloadATCD-0741d5a101d356bdad118fdcce07dac03f4ae7f3.tar.gz
ChangeLogTag: Wed Jun 25 13:55:00 UTC 2008 Simon Massey <sma at prismtech dot com>
-rw-r--r--TAO/ChangeLog29
-rw-r--r--TAO/orbsvcs/FTRT_Event_Service/Gateway_Service/FTRTEC_Gateway_Service.cpp21
-rw-r--r--TAO/orbsvcs/PSS/psdl_tao.cpp6
-rw-r--r--TAO/orbsvcs/examples/ImR/Advanced/TestClient.cpp10
-rw-r--r--TAO/orbsvcs/examples/ImR/Advanced/TestClient.h4
-rw-r--r--TAO/orbsvcs/examples/ImR/Advanced/TestServer.cpp20
-rw-r--r--TAO/orbsvcs/examples/ImR/Advanced/TestServer.h4
-rw-r--r--TAO/orbsvcs/examples/ImR/Advanced/client_main.cpp6
-rw-r--r--TAO/orbsvcs/examples/ImR/Advanced/manager_main.cpp8
-rw-r--r--TAO/orbsvcs/examples/ImR/Advanced/server_main.cpp6
-rw-r--r--TAO/orbsvcs/examples/ImR/Combined_Service/combined.cpp7
-rw-r--r--TAO/orbsvcs/examples/ImR/Combined_Service/controller.cpp23
-rw-r--r--TAO/orbsvcs/examples/ImR/Combined_Service/test_server.cpp6
-rw-r--r--TAO/orbsvcs/examples/PSS/client.cpp2
-rw-r--r--TAO/orbsvcs/performance-tests/RTEvent/Colocated_Roundtrip/driver.cpp2
-rw-r--r--TAO/orbsvcs/performance-tests/RTEvent/Federated_Roundtrip/client.cpp8
-rw-r--r--TAO/orbsvcs/performance-tests/RTEvent/Federated_Roundtrip/server.cpp6
-rw-r--r--TAO/orbsvcs/performance-tests/RTEvent/RTCORBA_Baseline/client.cpp2
-rw-r--r--TAO/orbsvcs/performance-tests/RTEvent/RTCORBA_Baseline/server.cpp6
-rw-r--r--TAO/orbsvcs/performance-tests/RTEvent/RTCORBA_Callback/client.cpp2
-rw-r--r--TAO/orbsvcs/performance-tests/RTEvent/RTCORBA_Callback/server.cpp6
-rw-r--r--TAO/orbsvcs/performance-tests/RTEvent/Roundtrip/client.cpp2
-rw-r--r--TAO/orbsvcs/performance-tests/RTEvent/Roundtrip/server.cpp6
-rw-r--r--TAO/orbsvcs/performance-tests/RTEvent/TCP_Baseline/client.cpp36
-rw-r--r--TAO/orbsvcs/performance-tests/RTEvent/TCP_Baseline/server.cpp26
25 files changed, 138 insertions, 116 deletions
diff --git a/TAO/ChangeLog b/TAO/ChangeLog
index 7924ae40aad..7ce0755ab6d 100644
--- a/TAO/ChangeLog
+++ b/TAO/ChangeLog
@@ -1,3 +1,32 @@
+Wed Jun 25 13:55:00 UTC 2008 Simon Massey <sma at prismtech dot com>
+
+ * orbsvcs/FTRT_Event_Service/Gateway_Service/FTRTEC_Gateway_Service.cpp:
+ * orbsvcs/performance-tests/RTEvent/TCP_Baseline/server.cpp:
+ * orbsvcs/performance-tests/RTEvent/TCP_Baseline/client.cpp:
+ * orbsvcs/performance-tests/RTEvent/Colocated_Roundtrip/driver.cpp:
+ * orbsvcs/performance-tests/RTEvent/Roundtrip/server.cpp:
+ * orbsvcs/performance-tests/RTEvent/Roundtrip/client.cpp:
+ * orbsvcs/performance-tests/RTEvent/RTCORBA_Baseline/server.cpp:
+ * orbsvcs/performance-tests/RTEvent/RTCORBA_Baseline/client.cpp:
+ * orbsvcs/performance-tests/RTEvent/Federated_Roundtrip/server.cpp:
+ * orbsvcs/performance-tests/RTEvent/Federated_Roundtrip/client.cpp:
+ * orbsvcs/performance-tests/RTEvent/RTCORBA_Callback/server.cpp:
+ * orbsvcs/performance-tests/RTEvent/RTCORBA_Callback/client.cpp:
+ * orbsvcs/examples/ImR/Combined_Service/combined.cpp:
+ * orbsvcs/examples/ImR/Combined_Service/test_server.cpp:
+ * orbsvcs/examples/ImR/Combined_Service/controller.cpp:
+ * orbsvcs/examples/ImR/Advanced/server_main.cpp:
+ * orbsvcs/examples/ImR/Advanced/TestServer.h:
+ * orbsvcs/examples/ImR/Advanced/TestServer.cpp:
+ * orbsvcs/examples/ImR/Advanced/client_main.cpp:
+ * orbsvcs/examples/ImR/Advanced/TestClient.h:
+ * orbsvcs/examples/ImR/Advanced/TestClient.cpp:
+ * orbsvcs/examples/ImR/Advanced/manager_main.cpp:
+ * orbsvcs/examples/PSS/client.cpp:
+ * orbsvcs/PSS/psdl_tao.cpp:
+
+ Fix fuzz errors incorrect ACE_TMAIN/main use.
+
Wed Jun 25 13:45:29 UTC 2008 J.T. Conklin <jtc@acorntoolworks.com>
* configure.ac:
diff --git a/TAO/orbsvcs/FTRT_Event_Service/Gateway_Service/FTRTEC_Gateway_Service.cpp b/TAO/orbsvcs/FTRT_Event_Service/Gateway_Service/FTRTEC_Gateway_Service.cpp
index 37438abed0e..35f280c4b30 100644
--- a/TAO/orbsvcs/FTRT_Event_Service/Gateway_Service/FTRTEC_Gateway_Service.cpp
+++ b/TAO/orbsvcs/FTRT_Event_Service/Gateway_Service/FTRTEC_Gateway_Service.cpp
@@ -18,17 +18,17 @@ ACE_RCSID (Gateway_Service,
namespace {
CORBA::ORB_var orb;
FtRtecEventChannelAdmin::EventChannel_var ftec;
- ACE_CString ior_file_name;
+ ACE_TString ior_file_name;
}
-int parse_args(int argc, ACE_TCHAR** argv)
+int parse_args (int argc, ACE_TCHAR *argv[])
{
try{
- ACE_Get_Opt get_opt (argc, argv, ACE_TEXT("i:n:o:"));
+ ACE_Get_Opt get_opt (argc, argv, ACE_TEXT ("i:n:o:"));
int opt;
CosNaming::Name name(1);
name.length(1);
- name[0].id = CORBA::string_dup("FT_EventService");
+ name[0].id = CORBA::string_dup ("FT_EventService");
while ((opt = get_opt ()) != EOF)
{
@@ -36,12 +36,12 @@ int parse_args(int argc, ACE_TCHAR** argv)
{
case 'i':
{
- CORBA::Object_var obj = orb->string_to_object(get_opt.opt_arg ());
- ftec = FtRtecEventChannelAdmin::EventChannel::_narrow(obj.in());
+ CORBA::Object_var obj = orb->string_to_object (ACE_TEXT_ALWAYS_CHAR (get_opt.opt_arg ()));
+ ftec = FtRtecEventChannelAdmin::EventChannel::_narrow (obj.in());
}
break;
case 'n':
- name[0].id = CORBA::string_dup(get_opt.opt_arg ());
+ name[0].id = CORBA::string_dup(ACE_TEXT_ALWAYS_CHAR (get_opt.opt_arg ()));
break;
case 'o':
ior_file_name = get_opt.opt_arg ();
@@ -68,13 +68,13 @@ int parse_args(int argc, ACE_TCHAR** argv)
return 0;
}
-int main(int argc, ACE_TCHAR** argv)
+int ACE_TMAIN (int argc, ACE_TCHAR *argv[])
{
try
{
orb = CORBA::ORB_init (argc, argv);
- if (parse_args(argc, argv)==-1)
+ if (parse_args (argc, argv) == -1)
return 1;
PortableServer::POA_var
@@ -97,8 +97,7 @@ int main(int argc, ACE_TCHAR** argv)
CORBA::String_var str = orb->object_to_string(gateway.in());
FILE *output_file=
- ACE_OS::fopen (ACE_TEXT_CHAR_TO_TCHAR(ior_file_name.c_str()),
- ACE_TEXT("w"));
+ ACE_OS::fopen (ior_file_name.c_str(), "w");
if (output_file == 0)
ACE_ERROR_RETURN ((LM_ERROR,
"Cannot open output file for writing IOR: %s",
diff --git a/TAO/orbsvcs/PSS/psdl_tao.cpp b/TAO/orbsvcs/PSS/psdl_tao.cpp
index 48491264b97..82d765ca145 100644
--- a/TAO/orbsvcs/PSS/psdl_tao.cpp
+++ b/TAO/orbsvcs/PSS/psdl_tao.cpp
@@ -4,7 +4,7 @@
#include "PSDL_Extern.h"
#include "Dump_Visitor.h"
-int main (int argc, char *argv [])
+int ACE_TMAIN (int argc, ACE_TCHAR *argv[])
{
void *result_ptr = 0;
@@ -15,9 +15,9 @@ int main (int argc, char *argv [])
else
psdl_extern.TAO_PSDL_Extern_yyin (ACE_OS::fopen (argv[1], "r"));
- ACE_OS::strtok (argv[1], ".");
+ ACE_OS::strtok (argv[1], ACE_TEXT ("."));
- TAO_PSDL_Scope::instance ()->set_stub_prefix (argv[1]);
+ TAO_PSDL_Scope::instance ()->set_stub_prefix (ACE_TEXT_ALWAYS_CHAR (argv[1]));
TAO_PSDL_Scope::instance ()->set_root_scope ();
// The syntax is checked and ASTs are build.
diff --git a/TAO/orbsvcs/examples/ImR/Advanced/TestClient.cpp b/TAO/orbsvcs/examples/ImR/Advanced/TestClient.cpp
index 63a9ad16eba..3a7f0b11629 100644
--- a/TAO/orbsvcs/examples/ImR/Advanced/TestClient.cpp
+++ b/TAO/orbsvcs/examples/ImR/Advanced/TestClient.cpp
@@ -9,7 +9,7 @@
#include "ace/OS_NS_stdlib.h"
#include "ace/Get_Opt.h"
-TestClient::TestClient(CORBA::ORB_ptr orb, int argc, char* argv[])
+TestClient::TestClient (CORBA::ORB_ptr orb, int argc, ACE_TCHAR *argv[])
: orb_(CORBA::ORB::_duplicate(orb))
, pauseType_('s')
, startupPause_(0)
@@ -22,16 +22,16 @@ TestClient::TestClient(CORBA::ORB_ptr orb, int argc, char* argv[])
, expectHolding_(false)
, expectNoProfile_(false)
{
- parseCommands(argc, argv);
+ parseCommands (argc, argv);
}
TestClient::~TestClient()
{
}
-int TestClient::parseCommands(int argc, char* argv[])
+int TestClient::parseCommands (int argc, ACE_TCHAR *argv[])
{
- ACE_Get_Opt get_opts(argc, argv, "s:t:i:r:x:e:z:");
+ ACE_Get_Opt get_opts (argc, argv, "s:t:i:r:x:e:z:");
int c;
while ((c = get_opts()) != -1)
{
@@ -252,7 +252,7 @@ int TestClient::svc()
catch (CORBA::Exception& ex)
{
ACE_ERROR((LM_ERROR,"CORBA client error with (%d.%d.%d.%d):%s\n",
- threadNum, i, objIter, requestIter, currentIOR.c_str()));
+ threadNum, i, objIter, requestIter, ACE_TEXT_CHAR_TO_TCHAR (currentIOR.c_str())));
ex._tao_print_exception ("");
}
return 1;
diff --git a/TAO/orbsvcs/examples/ImR/Advanced/TestClient.h b/TAO/orbsvcs/examples/ImR/Advanced/TestClient.h
index 237437daa5c..07b4193106d 100644
--- a/TAO/orbsvcs/examples/ImR/Advanced/TestClient.h
+++ b/TAO/orbsvcs/examples/ImR/Advanced/TestClient.h
@@ -10,14 +10,14 @@
class TestClient : public ACE_Task_Base, public ACE_Capabilities
{
public:
- TestClient(CORBA::ORB_ptr orb, int argc, char* argv[]);
+ TestClient (CORBA::ORB_ptr orb, int argc, ACE_TCHAR *argv[]);
virtual ~TestClient();
void run();
private:
- int parseCommands(int argc, char* argv[]);
+ int parseCommands (int argc, ACE_TCHAR *argv[]);
void buildIORList();
void pause(int milliseconds);
virtual int svc();
diff --git a/TAO/orbsvcs/examples/ImR/Advanced/TestServer.cpp b/TAO/orbsvcs/examples/ImR/Advanced/TestServer.cpp
index 155685a5baa..81b193a1576 100644
--- a/TAO/orbsvcs/examples/ImR/Advanced/TestServer.cpp
+++ b/TAO/orbsvcs/examples/ImR/Advanced/TestServer.cpp
@@ -123,7 +123,7 @@ string normalizePath(const string& dir, char delim, bool toLower)
return string(buffer);
}
-TestServer::TestServer(CORBA::ORB_ptr orb, int argc, char* argv[])
+TestServer::TestServer (CORBA::ORB_ptr orb, int argc, ACE_TCHAR *argv[])
: serverID_(1)
, serverInstanceID_(-1)
, useIORTable_(false)
@@ -142,7 +142,7 @@ TestServer::TestServer(CORBA::ORB_ptr orb, int argc, char* argv[])
, root_(PortableServer::POA::_nil())
, mgr_(PortableServer::POAManager::_nil())
{
- parseCommands(argc, argv);
+ parseCommands (argc, argv);
verifyEnvironment();
@@ -162,11 +162,11 @@ TestServer::~TestServer()
// TestServer::parseCommands
// Reads params from command line
//
-int TestServer::parseCommands(int argc, char* argv[])
+int TestServer::parseCommands (int argc, ACE_TCHAR *argv[])
{
- ACE_Get_Opt get_opts(argc, argv, "w:e:d:t:o:s:c:a:r:p:n:x:z:q:b:");
+ ACE_Get_Opt get_opts (argc, argv, "w:e:d:t:o:s:c:a:r:p:n:x:z:q:b:");
int c;
- while ((c = get_opts()) != -1)
+ while ((c = get_opts ()) != -1)
{
switch (c)
{
@@ -280,7 +280,7 @@ bool TestServer::verifyEnvironment() const
if (expectedDir_.empty() == false && currentDir != expectedDir_)
{
ACE_DEBUG((LM_DEBUG, "Error: directory paths (%s,%s) do not match.\n",
- currentDir.c_str(), expectedDir_.c_str()));
+ ACE_TEXT_CHAR_TO_TCHAR (currentDir.c_str()), ACE_TEXT_CHAR_TO_TCHAR (expectedDir_.c_str())));
err |= true;
}
@@ -291,13 +291,13 @@ bool TestServer::verifyEnvironment() const
if (realValue == 0)
{
ACE_DEBUG((LM_DEBUG, "Error, env variable '%s' not found\n",
- expectedEnv_[i].first.c_str()));
+ ACE_TEXT_CHAR_TO_TCHAR (expectedEnv_[i].first.c_str())));
err |= true;
}
else if (expectedEnv_[i].second != realValue)
{
ACE_DEBUG((LM_DEBUG, "Error, env variable '%s' values (%s,%s) do not match.\n",
- expectedEnv_[i].first.c_str(), realValue, expectedEnv_[i].second.c_str()));
+ ACE_TEXT_CHAR_TO_TCHAR (expectedEnv_[i].first.c_str()), ACE_TEXT_CHAR_TO_TCHAR (realValue), ACE_TEXT_CHAR_TO_TCHAR (expectedEnv_[i].second.c_str())));
err |= true;
}
}
@@ -452,7 +452,7 @@ void TestServer::buildObjects()
poaName = poaStream.str();
}
- ACE_DEBUG((LM_DEBUG, "* Creating POA: %s\n", poaName.c_str()));
+ ACE_DEBUG((LM_DEBUG, "* Creating POA: %s\n", ACE_TEXT_CHAR_TO_TCHAR (poaName.c_str())));
PortableServer::POA_var sub_poa = root_->create_POA(poaName.c_str(), mgr_.in(), policies);
@@ -467,7 +467,7 @@ void TestServer::buildObjects()
objStream << "OBJ_" << serverID_ << "_" << (i + 1) << "_" << (j + 1);
objName = objStream.str();
}
- ACE_DEBUG((LM_DEBUG, "* Activating Obj: %s\n", objName.c_str()));
+ ACE_DEBUG((LM_DEBUG, "* Activating Obj: %s\n", ACE_TEXT_CHAR_TO_TCHAR (objName.c_str())));
PortableServer::ObjectId_var oid = PortableServer::string_to_ObjectId(objName.c_str());
sub_poa->activate_object_with_id(oid.in(), servant_.get());
diff --git a/TAO/orbsvcs/examples/ImR/Advanced/TestServer.h b/TAO/orbsvcs/examples/ImR/Advanced/TestServer.h
index d18bd441c6b..862ab4732db 100644
--- a/TAO/orbsvcs/examples/ImR/Advanced/TestServer.h
+++ b/TAO/orbsvcs/examples/ImR/Advanced/TestServer.h
@@ -11,14 +11,14 @@
class TestServer
{
public:
- TestServer(CORBA::ORB_ptr, int argc, char* argv[]);
+ TestServer (CORBA::ORB_ptr, int argc, ACE_TCHAR *argv[]);
~TestServer();
void run();
private:
- int parseCommands(int argc, char* argv[]);
+ int parseCommands (int argc, ACE_TCHAR *argv[]);
bool verifyEnvironment() const;
bool registerWithManager();
void buildObjects();
diff --git a/TAO/orbsvcs/examples/ImR/Advanced/client_main.cpp b/TAO/orbsvcs/examples/ImR/Advanced/client_main.cpp
index bcebff9a94f..e3dc93eeafd 100644
--- a/TAO/orbsvcs/examples/ImR/Advanced/client_main.cpp
+++ b/TAO/orbsvcs/examples/ImR/Advanced/client_main.cpp
@@ -3,14 +3,14 @@
#include <ace/streams.h>
-int main(int argc, char* argv[])
+int ACE_TMAIN (int argc, ACE_TCHAR *argv[])
{
try
{
- CORBA::ORB_var orb = CORBA::ORB_init(argc, argv);
+ CORBA::ORB_var orb = CORBA::ORB_init (argc, argv);
{
- TestClient client(orb.in(), argc, argv);
+ TestClient client (orb.in (), argc, argv);
client.run();
}
diff --git a/TAO/orbsvcs/examples/ImR/Advanced/manager_main.cpp b/TAO/orbsvcs/examples/ImR/Advanced/manager_main.cpp
index 06c956c816c..30ee7d36e35 100644
--- a/TAO/orbsvcs/examples/ImR/Advanced/manager_main.cpp
+++ b/TAO/orbsvcs/examples/ImR/Advanced/manager_main.cpp
@@ -4,16 +4,16 @@
#include <ace/Get_Opt.h>
#include <ace/streams.h>
-int main(int argc, char* argv[])
+int ACE_TMAIN (int argc, ACE_TCHAR *argv[])
{
try
{
long retryCount = 0;
- CORBA::ORB_var orb = CORBA::ORB_init(argc, argv);
+ CORBA::ORB_var orb = CORBA::ORB_init (argc, argv);
- ACE_Get_Opt get_opts(argc, argv, "r:");
+ ACE_Get_Opt get_opts (argc, argv, "r:");
int c;
- while ((c = get_opts()) != -1)
+ while ((c = get_opts ()) != -1)
{
switch (c)
{
diff --git a/TAO/orbsvcs/examples/ImR/Advanced/server_main.cpp b/TAO/orbsvcs/examples/ImR/Advanced/server_main.cpp
index ccf813d0e9c..f145d5daaff 100644
--- a/TAO/orbsvcs/examples/ImR/Advanced/server_main.cpp
+++ b/TAO/orbsvcs/examples/ImR/Advanced/server_main.cpp
@@ -3,15 +3,15 @@
#include <ace/streams.h>
-int main(int argc, char* argv[])
+int ACE_TMAIN (int argc, ACE_TCHAR *argv[])
{
try
{
CORBA::ORB_var orb;
- orb = CORBA::ORB_init(argc, argv);
+ orb = CORBA::ORB_init (argc, argv);
{
- TestServer server(orb.in(), argc, argv);
+ TestServer server (orb.in(), argc, argv);
server.run();
}
diff --git a/TAO/orbsvcs/examples/ImR/Combined_Service/combined.cpp b/TAO/orbsvcs/examples/ImR/Combined_Service/combined.cpp
index 1bfe15b19fa..32cf01158a6 100644
--- a/TAO/orbsvcs/examples/ImR/Combined_Service/combined.cpp
+++ b/TAO/orbsvcs/examples/ImR/Combined_Service/combined.cpp
@@ -35,14 +35,14 @@ public:
}
};
-int main (int argc, char* argv[])
+int ACE_TMAIN (int argc, ACE_TCHAR *argv[])
{
try {
ACE_Service_Config config;
- config.open(argc, argv);
+ config.open (argc, argv);
- ORB_var orb = ORB_init(argc, argv);
+ ORB_var orb = ORB_init (argc, argv);
Object_var obj = orb->resolve_initial_references("RootPOA");
POA_var poa = POA::_narrow(obj.in());
@@ -77,4 +77,3 @@ int main (int argc, char* argv[])
}
return 0;
}
-
diff --git a/TAO/orbsvcs/examples/ImR/Combined_Service/controller.cpp b/TAO/orbsvcs/examples/ImR/Combined_Service/controller.cpp
index 2985512d78c..d7980f786ca 100644
--- a/TAO/orbsvcs/examples/ImR/Combined_Service/controller.cpp
+++ b/TAO/orbsvcs/examples/ImR/Combined_Service/controller.cpp
@@ -10,27 +10,26 @@
using namespace CORBA;
namespace {
-
- ACE_CString directive;
+ ACE_TString directive;
void showusage() {
ACE_DEBUG((LM_DEBUG, "Usage: controller [-r | -c \"service_configurator_directive\"]\n"
"(e.g. dynamic mysvc Service_Object * MySvc:_make_MySvc() \"-arg1 one\"\n\n"));
}
- bool parse_args(int argc, char* argv[]) {
+ bool parse_args (int argc, ACE_TCHAR *argv[]) {
if (argc != 2 && argc != 3) {
ACE_ERROR((LM_ERROR, "Controller: wrong number of arguments. %d\n", argc - 1));
return false;
}
for (int i = 1; i < argc; ++i) {
- ACE_CString s(argv[i]);
- if (s == "-h" || s == "-help" || s == "--help" || s == "-?")
+ ACE_TString s (argv[i]);
+ if (s == ACE_TEXT ("-h") || s == ACE_TEXT ("-help") || s == ACE_TEXT ("--help") || s == ACE_TEXT ("-?"))
return false;
- if (s == "-r") {
+ if (s == ACE_TEXT ("-r")) {
return true;
}
- if (s == "-c" && ++i < argc) {
+ if (s == ACE_TEXT ("-c") && ++i < argc) {
directive = argv[i];
return true;
}
@@ -39,13 +38,11 @@ namespace {
}
}
-int main(int argc, char* argv[]) {
-
+int ACE_TMAIN (int argc, ACE_TCHAR *argv[]) {
try {
+ ORB_var orb = ORB_init (argc, argv);
- ORB_var orb = ORB_init(argc, argv);
-
- if (! parse_args(argc, argv)) {
+ if (! parse_args (argc, argv)) {
showusage();
return 1;
}
@@ -58,7 +55,7 @@ int main(int argc, char* argv[]) {
if (directive.length() > 0) {
ACE_DEBUG((LM_DEBUG, "Controller: sending directive <%s>...\n", directive.c_str()));
- sc->process_directive(directive.c_str());
+ sc->process_directive (ACE_TEXT_ALWAYS_CHAR (directive.c_str()));
} else {
ACE_DEBUG((LM_DEBUG, "Controller: reloading config file...\n"));
sc->reconfigure();
diff --git a/TAO/orbsvcs/examples/ImR/Combined_Service/test_server.cpp b/TAO/orbsvcs/examples/ImR/Combined_Service/test_server.cpp
index 3f654bfa934..b7b870f445e 100644
--- a/TAO/orbsvcs/examples/ImR/Combined_Service/test_server.cpp
+++ b/TAO/orbsvcs/examples/ImR/Combined_Service/test_server.cpp
@@ -39,11 +39,9 @@ POA_ptr createPersistPOA(const char* name, POA_ptr root_poa, POAManager_ptr poam
return poa._retn();
}
-int main(int argc, char* argv[]) {
-
+int ACE_TMAIN (int argc, ACE_TCHAR *argv[]) {
try {
-
- ORB_var orb = ORB_init(argc, argv);
+ ORB_var orb = ORB_init (argc, argv);
Object_var obj = orb->resolve_initial_references("RootPOA");
POA_var root_poa = POA::_narrow(obj.in());
diff --git a/TAO/orbsvcs/examples/PSS/client.cpp b/TAO/orbsvcs/examples/PSS/client.cpp
index b8915110e0e..b033db76d82 100644
--- a/TAO/orbsvcs/examples/PSS/client.cpp
+++ b/TAO/orbsvcs/examples/PSS/client.cpp
@@ -23,7 +23,7 @@
#include "ServerC.h"
#include "Simple_Naming_i.h"
-int main (int argc, char *argv [])
+int ACE_TMAIN (int argc, ACE_TCHAR *argv[])
{
try
diff --git a/TAO/orbsvcs/performance-tests/RTEvent/Colocated_Roundtrip/driver.cpp b/TAO/orbsvcs/performance-tests/RTEvent/Colocated_Roundtrip/driver.cpp
index 0712a57e703..4794a2454ec 100644
--- a/TAO/orbsvcs/performance-tests/RTEvent/Colocated_Roundtrip/driver.cpp
+++ b/TAO/orbsvcs/performance-tests/RTEvent/Colocated_Roundtrip/driver.cpp
@@ -32,7 +32,7 @@
ACE_RCSID(TAO_PERF_RTEC_Colocated_Roundtrip, driver, "$Id$")
-int main (int argc, char *argv[])
+int ACE_TMAIN (int argc, ACE_TCHAR *argv[])
{
const CORBA::Long experiment_id = 1;
diff --git a/TAO/orbsvcs/performance-tests/RTEvent/Federated_Roundtrip/client.cpp b/TAO/orbsvcs/performance-tests/RTEvent/Federated_Roundtrip/client.cpp
index 0870f02aded..4fe176cf052 100644
--- a/TAO/orbsvcs/performance-tests/RTEvent/Federated_Roundtrip/client.cpp
+++ b/TAO/orbsvcs/performance-tests/RTEvent/Federated_Roundtrip/client.cpp
@@ -30,7 +30,7 @@
ACE_RCSID(TAO_RTEC_PERF_Roundtrip, client, "$Id$")
-const char *ior = "file://test.ior";
+const ACE_TCHAR *ior = ACE_TEXT ("file://test.ior");
int nthreads = 0;
int high_priority_period = 0;
int high_priority_workload = 0;
@@ -63,7 +63,7 @@ private:
};
int
-parse_args (int argc, char *argv[])
+parse_args (int argc, ACE_TCHAR *argv[])
{
ACE_Get_Opt get_opts (argc, argv, "k:n:l:h:w:v:zr");
int c;
@@ -124,7 +124,7 @@ parse_args (int argc, char *argv[])
return 0;
}
-int main (int argc, char *argv[])
+int ACE_TMAIN (int argc, ACE_TCHAR *argv[])
{
TAO_EC_Default_Factory::init_svcs();
RT_Class rt_class;
@@ -164,7 +164,7 @@ int main (int argc, char *argv[])
ACE_DEBUG ((LM_DEBUG, "Finished peer configuration and activation\n"));
CORBA::Object_var object =
- orb->string_to_object (ior);
+ orb->string_to_object (ACE_TEXT_ALWAYS_CHAR (ior));
Federated_Test::Control_var control =
Federated_Test::Control::_narrow (object.in ());
diff --git a/TAO/orbsvcs/performance-tests/RTEvent/Federated_Roundtrip/server.cpp b/TAO/orbsvcs/performance-tests/RTEvent/Federated_Roundtrip/server.cpp
index f6194ba73dd..3cc046d687c 100644
--- a/TAO/orbsvcs/performance-tests/RTEvent/Federated_Roundtrip/server.cpp
+++ b/TAO/orbsvcs/performance-tests/RTEvent/Federated_Roundtrip/server.cpp
@@ -18,7 +18,7 @@ ACE_RCSID (TAO_PERF_RTEC_Federated_Roundtrip,
server,
"$Id$")
-const char *ior_output_file = "test.ior";
+const ACE_TCHAR *ior_output_file = ACE_TEXT ("test.ior");
int iterations = 10000;
int nthreads = 1;
int peer_count = 2;
@@ -26,7 +26,7 @@ int do_dump_history = 0;
int use_rt_corba = 0;
int
-parse_args (int argc, char *argv[])
+parse_args (int argc, ACE_TCHAR *argv[])
{
ACE_Get_Opt get_opts (argc, argv, "o:i:p:n:rd");
int c;
@@ -76,7 +76,7 @@ parse_args (int argc, char *argv[])
return 0;
}
-int main (int argc, char *argv[])
+int ACE_TMAIN (int argc, ACE_TCHAR *argv[])
{
RT_Class rt_class;
diff --git a/TAO/orbsvcs/performance-tests/RTEvent/RTCORBA_Baseline/client.cpp b/TAO/orbsvcs/performance-tests/RTEvent/RTCORBA_Baseline/client.cpp
index 22ba06395b5..3dcb763f47d 100644
--- a/TAO/orbsvcs/performance-tests/RTEvent/RTCORBA_Baseline/client.cpp
+++ b/TAO/orbsvcs/performance-tests/RTEvent/RTCORBA_Baseline/client.cpp
@@ -156,7 +156,7 @@ private:
int workload_;
};
-int main (int argc, char *argv[])
+int ACE_TMAIN (int argc, ACE_TCHAR *argv[])
{
RT_Class rt_class;
diff --git a/TAO/orbsvcs/performance-tests/RTEvent/RTCORBA_Baseline/server.cpp b/TAO/orbsvcs/performance-tests/RTEvent/RTCORBA_Baseline/server.cpp
index aaf0be0d9be..389aa84e774 100644
--- a/TAO/orbsvcs/performance-tests/RTEvent/RTCORBA_Baseline/server.cpp
+++ b/TAO/orbsvcs/performance-tests/RTEvent/RTCORBA_Baseline/server.cpp
@@ -18,12 +18,12 @@ ACE_RCSID (TAO_PERF_RTEC_RTCORBA_Baseline,
server,
"$Id$")
-const char *ior_output_file = "test.ior";
+const ACE_TCHAR *ior_output_file = ACE_TEXT ("test.ior");
int use_rt_corba = 0;
int nthreads = 0;
int
-parse_args (int argc, char *argv[])
+parse_args (int argc, ACE_TCHAR *argv[])
{
ACE_Get_Opt get_opts (argc, argv, "o:n:r");
int c;
@@ -58,7 +58,7 @@ parse_args (int argc, char *argv[])
return 0;
}
-int main (int argc, char *argv[])
+int ACE_TMAIN (int argc, ACE_TCHAR *argv[])
{
/// Move the test to the real-time class if it is possible.
RT_Class rt_class;
diff --git a/TAO/orbsvcs/performance-tests/RTEvent/RTCORBA_Callback/client.cpp b/TAO/orbsvcs/performance-tests/RTEvent/RTCORBA_Callback/client.cpp
index 9d0e2bcea31..16775d9c59a 100644
--- a/TAO/orbsvcs/performance-tests/RTEvent/RTCORBA_Callback/client.cpp
+++ b/TAO/orbsvcs/performance-tests/RTEvent/RTCORBA_Callback/client.cpp
@@ -180,7 +180,7 @@ private:
int period_in_usecs_;
};
-int main (int argc, char *argv[])
+int ACE_TMAIN (int argc, ACE_TCHAR *argv[])
{
/// Move the test to the real-time class if it is possible.
RT_Class rt_class;
diff --git a/TAO/orbsvcs/performance-tests/RTEvent/RTCORBA_Callback/server.cpp b/TAO/orbsvcs/performance-tests/RTEvent/RTCORBA_Callback/server.cpp
index 81143039133..ada87d85c2f 100644
--- a/TAO/orbsvcs/performance-tests/RTEvent/RTCORBA_Callback/server.cpp
+++ b/TAO/orbsvcs/performance-tests/RTEvent/RTCORBA_Callback/server.cpp
@@ -21,12 +21,12 @@ ACE_RCSID (TAO_PERF_RTEC_RTCORBA_Baseline,
server,
"$Id$")
-const char *ior_output_file = "test.ior";
+const ACE_TCHAR *ior_output_file = ACE_TEXT ("test.ior");
int use_rt_corba = 0;
int nthreads = 0;
int
-parse_args (int argc, char *argv[])
+parse_args (int argc, ACE_TCHAR *argv[])
{
ACE_Get_Opt get_opts (argc, argv, "o:n:r");
int c;
@@ -61,7 +61,7 @@ parse_args (int argc, char *argv[])
return 0;
}
-int main (int argc, char *argv[])
+int ACE_TMAIN (int argc, ACE_TCHAR *argv[])
{
/// Move the test to the real-time class if it is possible.
RT_Class rt_class;
diff --git a/TAO/orbsvcs/performance-tests/RTEvent/Roundtrip/client.cpp b/TAO/orbsvcs/performance-tests/RTEvent/Roundtrip/client.cpp
index bd774077776..03b2b09bb47 100644
--- a/TAO/orbsvcs/performance-tests/RTEvent/Roundtrip/client.cpp
+++ b/TAO/orbsvcs/performance-tests/RTEvent/Roundtrip/client.cpp
@@ -29,7 +29,7 @@
ACE_RCSID(TAO_RTEC_PERF_Roundtrip, client, "$Id$")
-int main (int argc, char *argv[])
+int ACE_TMAIN (int argc, ACE_TCHAR *argv[])
{
const CORBA::Long experiment_id = 1;
diff --git a/TAO/orbsvcs/performance-tests/RTEvent/Roundtrip/server.cpp b/TAO/orbsvcs/performance-tests/RTEvent/Roundtrip/server.cpp
index 86f6fc8fe95..88c7bc85a35 100644
--- a/TAO/orbsvcs/performance-tests/RTEvent/Roundtrip/server.cpp
+++ b/TAO/orbsvcs/performance-tests/RTEvent/Roundtrip/server.cpp
@@ -23,12 +23,12 @@ ACE_RCSID (TAO_PERF_RTEC_Roundtrip,
server,
"$Id$")
-const char *ior_output_file = "test.ior";
+const ACE_TCHAR *ior_output_file = ACE_TEXT ("test.ior");
int use_rt_corba = 0;
int nthreads = 0;
int
-parse_args (int argc, char *argv[])
+parse_args (int argc, ACE_TCHAR *argv[])
{
ACE_Get_Opt get_opts (argc, argv, "o:n:r");
int c;
@@ -63,7 +63,7 @@ parse_args (int argc, char *argv[])
return 0;
}
-int main (int argc, char *argv[])
+int ACE_TMAIN (int argc, ACE_TCHAR *argv[])
{
TAO_EC_Default_Factory::init_svcs ();
diff --git a/TAO/orbsvcs/performance-tests/RTEvent/TCP_Baseline/client.cpp b/TAO/orbsvcs/performance-tests/RTEvent/TCP_Baseline/client.cpp
index ee18997a132..432af8fd712 100644
--- a/TAO/orbsvcs/performance-tests/RTEvent/TCP_Baseline/client.cpp
+++ b/TAO/orbsvcs/performance-tests/RTEvent/TCP_Baseline/client.cpp
@@ -19,16 +19,16 @@ ACE_RCSID (TAO_RTEC_PERF_TCP_Baseline,
client,
"$Id$")
-char const * hi_endpoint = "localhost:12345";
-char const * lo_endpoint = "localhost:23456";
+char ACE_TCHAR *hi_endpoint = ACE_TEXT ("localhost:12345");
+char ACE_TCHAR *lo_endpoint = ACE_TEXT ("localhost:23456");
int
-parse_args (int argc, char *argv[]);
+parse_args (int argc, ACE_TCHAR *argv[]);
class Scavenger_Task : public ACE_Task_Base
{
public:
- Scavenger_Task (char const * endpoint,
+ Scavenger_Task (ACE_TCHAR const * endpoint,
ACE_Barrier * the_barrier,
int period_in_usecs);
@@ -37,7 +37,7 @@ public:
virtual int svc ();
private:
- char const * endpoint_;
+ ACE_TCHAR const * endpoint_;
ACE_Barrier * the_barrier_;
int period_in_usecs_;
TAO_SYNCH_MUTEX mutex_;
@@ -47,7 +47,7 @@ private:
class Measuring_Task : public ACE_Task_Base
{
public:
- Measuring_Task (char const * endpoint,
+ Measuring_Task (ACE_TCHAR const * endpoint,
ACE_Barrier *the_barrier,
int iterations,
int period_in_usecs);
@@ -57,13 +57,13 @@ public:
ACE_Sample_History sample_history;
private:
- char const * endpoint_;
+ ACE_TCHAR const * endpoint_;
ACE_Barrier * the_barrier_;
int iterations_;
int period_in_usecs_;
};
-int main (int argc, char *argv[])
+int ACE_TMAIN (int argc, ACE_TCHAR *argv[])
{
RT_Class rt_class;
@@ -122,7 +122,7 @@ int main (int argc, char *argv[])
// ****************************************************************
-Scavenger_Task::Scavenger_Task(char const * endpoint,
+Scavenger_Task::Scavenger_Task(ACE_TCHAR const * endpoint,
ACE_Barrier * the_barrier,
int period_in_usecs)
: endpoint_ (endpoint)
@@ -194,14 +194,14 @@ Scavenger_Task::svc(void)
// ****************************************************************
-Measuring_Task::Measuring_Task (char const * endpoint,
+Measuring_Task::Measuring_Task (ACE_TCHAR const * endpoint,
ACE_Barrier * the_barrier,
int iterations,
int period_in_usecs)
: sample_history (iterations)
- , endpoint_(endpoint)
- , the_barrier_(the_barrier)
- , iterations_ (iterations)
+ , endpoint_ (endpoint)
+ , the_barrier_ (the_barrier)
+ , iterations_ (iterations)
, period_in_usecs_ (period_in_usecs)
{
}
@@ -233,12 +233,12 @@ Measuring_Task::svc ()
if (n == 0) {
ACE_ERROR((LM_ERROR,
"Connection closed while writing data to server <%s>\n",
- endpoint_, ""));
+ endpoint_));
break;
} else if (n == -1) {
ACE_ERROR((LM_ERROR,
"Error writing data to server <%s> %p\n",
- endpoint_, ""));
+ endpoint_));
break;
}
if (n == 0 || n == -1)
@@ -253,12 +253,12 @@ Measuring_Task::svc ()
if (n == 0) {
ACE_ERROR((LM_ERROR,
"Connection closed while reading data from server <%s>\n",
- endpoint_, ""));
+ endpoint_));
break;
} else if (n == -1) {
ACE_ERROR((LM_ERROR,
"Error reading data from server <%s> %p\n",
- endpoint_, ""));
+ endpoint_));
break;
}
@@ -279,7 +279,7 @@ Measuring_Task::svc ()
}
int
-parse_args (int argc, char *argv[])
+parse_args (int argc, ACE_TCHAR *argv[])
{
ACE_Get_Opt get_opts (argc, argv, "H:L:");
int c;
diff --git a/TAO/orbsvcs/performance-tests/RTEvent/TCP_Baseline/server.cpp b/TAO/orbsvcs/performance-tests/RTEvent/TCP_Baseline/server.cpp
index dcbfac08567..98209718d75 100644
--- a/TAO/orbsvcs/performance-tests/RTEvent/TCP_Baseline/server.cpp
+++ b/TAO/orbsvcs/performance-tests/RTEvent/TCP_Baseline/server.cpp
@@ -17,26 +17,26 @@ ACE_RCSID (TAO_PERF_RTEC_TCP_Baseline,
int use_rt = 0;
int nthreads = 1;
-char const * hi_endpoint = "localhost:12345";
-char const * lo_endpoint = "localhost:23456";
+ACE_TCHAR const * hi_endpoint = ACE_TEXT ("localhost:12345");
+ACE_TCHAR const * lo_endpoint = ACE_TEXT ("localhost:23456");
int
-parse_args (int argc, char *argv[]);
+parse_args (int argc, ACE_TCHAR *argv[]);
class Task : public ACE_Task_Base
{
public:
- Task(char const * endpoint);
+ Task (ACE_TCHAR const *endpoint);
virtual int svc();
private:
- char const * endpoint_;
+ ACE_TCHAR const *endpoint_;
ACE_Reactor reactor_;
};
-int main (int argc, char *argv[])
+int ACE_TMAIN (int argc, ACE_TCHAR *argv[])
{
/// Move the test to the real-time class if it is possible.
RT_Class rt_class;
@@ -44,8 +44,8 @@ int main (int argc, char *argv[])
if (parse_args (argc, argv) != 0)
return 1;
- Task hi_task(hi_endpoint);
- Task lo_task(lo_endpoint);
+ Task hi_task (hi_endpoint);
+ Task lo_task (lo_endpoint);
hi_task.activate(rt_class.thr_sched_class() | THR_NEW_LWP | THR_JOINABLE,
1, 1, rt_class.priority_high());
@@ -139,11 +139,11 @@ Svc_Handler::handle_close(ACE_HANDLE h, ACE_Reactor_Mask m)
// ****************************************************************
-Task::Task(char const * endpoint)
- : endpoint_(endpoint)
- , reactor_(new ACE_TP_Reactor)
+Task::Task(ACE_TCHAR const * endpoint)
+ : endpoint_ (endpoint)
+ , reactor_ (new ACE_TP_Reactor)
{
- ACE_INET_Addr local_sap(endpoint_);
+ ACE_INET_Addr local_sap (endpoint_);
Acceptor * acceptor = new Acceptor;
if(acceptor->open(local_sap, &reactor_, ACE_NONBLOCK) == -1)
@@ -163,7 +163,7 @@ Task::svc()
// ****************************************************************
int
-parse_args (int argc, char *argv[])
+parse_args (int argc, ACE_TCHAR *argv[])
{
ACE_Get_Opt get_opts (argc, argv, "h:l:n:r");
int c;