summaryrefslogtreecommitdiff
path: root/TAO/tao/CORBANAME_Parser.cpp
diff options
context:
space:
mode:
authorPhil Mesnier <mesnier_p@ociweb.com>2005-04-10 02:25:32 +0000
committerPhil Mesnier <mesnier_p@ociweb.com>2005-04-10 02:25:32 +0000
commitbca0fe7d5ad39e1d3f9a6654bb4e00d6e8c94548 (patch)
treee121754889c3d209bba23c32a6c15fc721b3cc9e /TAO/tao/CORBANAME_Parser.cpp
parentfdf30e5d0d7fbb7bd3889131206fa23db51b0ce4 (diff)
downloadATCD-bca0fe7d5ad39e1d3f9a6654bb4e00d6e8c94548.tar.gz
ChangeLog tag: Sat Apr 9 21:19:51 2005 Phil Mesnier <mesnier_p@ociweb.com>
Diffstat (limited to 'TAO/tao/CORBANAME_Parser.cpp')
-rw-r--r--TAO/tao/CORBANAME_Parser.cpp26
1 files changed, 5 insertions, 21 deletions
diff --git a/TAO/tao/CORBANAME_Parser.cpp b/TAO/tao/CORBANAME_Parser.cpp
index e330e093a26..ec3998eb794 100644
--- a/TAO/tao/CORBANAME_Parser.cpp
+++ b/TAO/tao/CORBANAME_Parser.cpp
@@ -81,8 +81,6 @@ TAO_CORBANAME_Parser::parse_string (const char *ior,
ACE_TRY
{
- char rir_prot [] = "rir:";
-
// The position of the seperator between the obj_addr and key
// string
CORBA::ULong pos_seperator = 0;
@@ -96,26 +94,12 @@ TAO_CORBANAME_Parser::parse_string (const char *ior,
corbaname_str.substring (pos_seperator + 1,
-1);
- // Make it in a form understandable by <corbaloc> scheme
+ // Prepare a suitable corbaloc string for the name service.
+ // CORBALOC assumes "NameService" for the object key if none
+ // is provided, so just pass everything between "corbaname:"
+ // and "#" as the address
ACE_CString corbaloc_addr ("corbaloc:", 0, 1);
-
- if (ACE_OS::strncmp (corbaname,
- rir_prot,
- sizeof (rir_prot)) != 0)
- {
- // Implies that <iiop:> protocol is to be used.
- // So .. we need to get the host address where an object of
- // type NamingContext can be found.
- // Get the obj_addr
- ACE_CString obj_addr = corbaname_str.substring (0,
- pos_seperator);
-
- corbaloc_addr += obj_addr;
-
- }
-
- ACE_CString name_service ("/NameService", 0, 1);
- corbaloc_addr += name_service;
+ corbaloc_addr += corbaname_str.substring (0, pos_seperator);
// Obtain a reference to the naming context
CORBA::Object_var name_context =