summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorJohnny Willemsen <jwillemsen@remedy.nl>2008-10-06 19:41:15 +0000
committerJohnny Willemsen <jwillemsen@remedy.nl>2008-10-06 19:41:15 +0000
commit2d594e7fa21629f8b9e69578ab0c5bdae0bb893b (patch)
tree8418583a464752d9f939fe08113688a6330f5b27
parent3fc3ed57c4a5b11e3bf9e4ddcd1a5821dc47730c (diff)
downloadATCD-2d594e7fa21629f8b9e69578ab0c5bdae0bb893b.tar.gz
-rw-r--r--TAO/examples/Callback_Quoter/Consumer_Handler.cpp12
-rw-r--r--TAO/examples/Callback_Quoter/Consumer_Handler.h2
-rw-r--r--TAO/examples/Callback_Quoter/Supplier_i.cpp18
-rw-r--r--TAO/examples/Callback_Quoter/Supplier_i.h4
4 files changed, 18 insertions, 18 deletions
diff --git a/TAO/examples/Callback_Quoter/Consumer_Handler.cpp b/TAO/examples/Callback_Quoter/Consumer_Handler.cpp
index 8f3ecd1682e..a55d5dcd52e 100644
--- a/TAO/examples/Callback_Quoter/Consumer_Handler.cpp
+++ b/TAO/examples/Callback_Quoter/Consumer_Handler.cpp
@@ -81,7 +81,7 @@ Consumer_Handler::read_ior (ACE_TCHAR *filename)
"Unable to read ior: %p\n"),
-1);
- this->ior_ = ACE_OS::strdup (data);
+ this->ior_ = ACE_OS::strdup (ACE_TEXT_CHAR_TO_TCHAR(data));
ior_buffer.alloc ()->free (data);
ACE_OS::close (f_handle);
@@ -114,7 +114,7 @@ Consumer_Handler::parse_args (void)
if (result < 0)
ACE_ERROR_RETURN ((LM_ERROR,
"Unable to read ior from %s : %p\n",
- ACE_TEXT_CHAR_TO_TCHAR (get_opts.opt_arg ())),
+ get_opts.opt_arg ()),
-1);
break;
@@ -123,7 +123,7 @@ Consumer_Handler::parse_args (void)
break;
case 'a': // to be given only on using run_test.pl
- this->stock_name_ = get_opts.opt_arg ();
+ this->stock_name_ = ACE_TEXT_ALWAYS_CHAR(get_opts.opt_arg ());
this->interactive_ = 0;
break;
@@ -148,7 +148,7 @@ Consumer_Handler::parse_args (void)
" [-a stock_name]"
" [-t threshold]"
"\n",
- ACE_TEXT_CHAR_TO_TCHAR (this->argv_ [0])),
+ this->argv_ [0]),
-1);
}
@@ -264,7 +264,7 @@ Consumer_Handler::init (int argc, ACE_TCHAR **argv)
if (this->ior_ == 0)
ACE_ERROR_RETURN ((LM_ERROR,
"%s: no ior specified\n",
- ACE_TEXT_CHAR_TO_TCHAR (this->argv_[0])),
+ this->argv_[0]),
-1);
CORBA::Object_var server_object =
@@ -273,7 +273,7 @@ Consumer_Handler::init (int argc, ACE_TCHAR **argv)
if (CORBA::is_nil (server_object.in ()))
ACE_ERROR_RETURN ((LM_ERROR,
"invalid ior <%s>\n",
- ACE_TEXT_CHAR_TO_TCHAR (this->ior_)),
+ this->ior_),
-1);
// The downcasting from CORBA::Object_var to Notifier_var is
// done using the <_narrow> method.
diff --git a/TAO/examples/Callback_Quoter/Consumer_Handler.h b/TAO/examples/Callback_Quoter/Consumer_Handler.h
index 853a2f9f401..20cc7745e3d 100644
--- a/TAO/examples/Callback_Quoter/Consumer_Handler.h
+++ b/TAO/examples/Callback_Quoter/Consumer_Handler.h
@@ -111,7 +111,7 @@ private:
ACE_TCHAR **argv_;
// arguments from command line.
- char *ior_;
+ ACE_TCHAR *ior_;
// IOR of the obj ref of the server.
int shutdown_;
diff --git a/TAO/examples/Callback_Quoter/Supplier_i.cpp b/TAO/examples/Callback_Quoter/Supplier_i.cpp
index ceab107ed10..36f9af89128 100644
--- a/TAO/examples/Callback_Quoter/Supplier_i.cpp
+++ b/TAO/examples/Callback_Quoter/Supplier_i.cpp
@@ -73,7 +73,7 @@ Supplier::read_ior (ACE_TCHAR *filename)
"Unable to read ior\n"),
-1);
- this->ior_ = ACE_OS::strdup (data);
+ this->ior_ = ACE_OS::strdup (ACE_TEXT_CHAR_TO_TCHAR(data));
ior_buffer.alloc ()->free (data);
ACE_OS::close (f_handle);
@@ -107,7 +107,7 @@ Supplier::parse_args (void)
if (result < 0)
ACE_ERROR_RETURN ((LM_ERROR,
"Unable to read stock information from %s : %p\n",
- ACE_TEXT_CHAR_TO_TCHAR (get_opts.opt_arg ())),
+ get_opts.opt_arg ()),
-1);
break;
@@ -120,7 +120,7 @@ Supplier::parse_args (void)
if (result < 0)
ACE_ERROR_RETURN ((LM_ERROR,
"Unable to read ior from %s : %p\n",
- ACE_TEXT_CHAR_TO_TCHAR (get_opts.opt_arg ())),
+ get_opts.opt_arg ()),
-1);
break;
@@ -140,7 +140,7 @@ Supplier::parse_args (void)
" [-x]"
" [-s]"
"\n",
- ACE_TEXT_CHAR_TO_TCHAR (this->argv_ [0])),
+ this->argv_ [0]),
-1);
}
@@ -277,7 +277,7 @@ Supplier::init (int argc, ACE_TCHAR **argv)
if (this->ior_ == 0)
ACE_ERROR_RETURN ((LM_ERROR,
"%s: no ior specified\n",
- ACE_TEXT_CHAR_TO_TCHAR (this->argv_[0])),
+ this->argv_[0]),
-1);
CORBA::Object_var notifier_object =
this->orb_->string_to_object (this->ior_);
@@ -285,7 +285,7 @@ Supplier::init (int argc, ACE_TCHAR **argv)
if (CORBA::is_nil (notifier_object.in ()))
ACE_ERROR_RETURN ((LM_ERROR,
"invalid ior <%s>\n",
- ACE_TEXT_CHAR_TO_TCHAR (this->ior_)),
+ this->ior_),
-1);
// The downcasting from CORBA::Object_var to Notifier_var is
// done using the <_narrow> method.
@@ -314,19 +314,19 @@ Supplier::reactor_used (void) const
// The stock market information is read from a file.
int
-Supplier::read_file (char *filename)
+Supplier::read_file (ACE_TCHAR *filename)
{
f_ptr_ = ACE_OS::fopen (filename, "r");
ACE_DEBUG ((LM_DEBUG,
"filename = %s\n",
- ACE_TEXT_CHAR_TO_TCHAR (filename)));
+ filename));
// the stock values are to be read from a file.
if (f_ptr_ == 0)
ACE_ERROR_RETURN ((LM_ERROR,
"Unable to open %s for writing: %p\n",
- ACE_TEXT_CHAR_TO_TCHAR (filename)),
+ filename),
-1);
return 0;
}
diff --git a/TAO/examples/Callback_Quoter/Supplier_i.h b/TAO/examples/Callback_Quoter/Supplier_i.h
index b1b70dd244e..181e1771c75 100644
--- a/TAO/examples/Callback_Quoter/Supplier_i.h
+++ b/TAO/examples/Callback_Quoter/Supplier_i.h
@@ -78,7 +78,7 @@ private:
ACE_Reactor *reactor_used (void) const;
// returns the TAO instance of the singleton Reactor.
- int read_file (char *filename);
+ int read_file (ACE_TCHAR *filename);
// This method used for getting stock information from a file.
int argc_;
@@ -87,7 +87,7 @@ private:
ACE_TCHAR **argv_;
// arguments from command line.
- char *ior_;
+ ACE_TCHAR *ior_;
// IOR of the obj ref of the Notifier.
TAO_Naming_Client naming_services_client_;