summaryrefslogtreecommitdiff
path: root/modules/CIAO/DAnCE/Plan_Launcher/Plan_Launcher_Base_Impl_T.cpp
diff options
context:
space:
mode:
Diffstat (limited to 'modules/CIAO/DAnCE/Plan_Launcher/Plan_Launcher_Base_Impl_T.cpp')
-rw-r--r--modules/CIAO/DAnCE/Plan_Launcher/Plan_Launcher_Base_Impl_T.cpp24
1 files changed, 16 insertions, 8 deletions
diff --git a/modules/CIAO/DAnCE/Plan_Launcher/Plan_Launcher_Base_Impl_T.cpp b/modules/CIAO/DAnCE/Plan_Launcher/Plan_Launcher_Base_Impl_T.cpp
index 2bd3fcad161..01628d9b1bc 100644
--- a/modules/CIAO/DAnCE/Plan_Launcher/Plan_Launcher_Base_Impl_T.cpp
+++ b/modules/CIAO/DAnCE/Plan_Launcher/Plan_Launcher_Base_Impl_T.cpp
@@ -586,10 +586,10 @@ namespace DAnCE
for (CORBA::ULong i = 0; i < plan.connection.length(); i++)
{
- if (plan.connection[i].externalReference.length() > 0
- && plan.connection[i].externalReference[0].provider)
+ if (plan.connection[i].externalReference.length() > 0)
+ //&& plan.connection[i].externalReference[0].provider)
{
- DANCE_DEBUG (6, (LM_DEBUG,
+ DANCE_DEBUG (6, (LM_DEBUG, DLINFO
"Plan_Launcher_i::create_external_connections - create connection %C from IOR %C\n",
plan.connection[i].name.in(),
plan.connection[i].externalReference[0].location.in()));
@@ -598,10 +598,18 @@ namespace DAnCE
{
CORBA::Object_ptr
obj = this->orb_->string_to_object(plan.connection[i].externalReference[0].location.in());
+
if (!CORBA::is_nil (obj))
{
- CORBA::ULong const indx = conn.length();
- conn.length(indx + 1);
+ CORBA::ULong indx = 0;
+ for (; indx < conn.length (); ++indx)
+
+ if (ACE_OS::strcmp (conn[indx].name.in (),
+ plan.connection[i].name.in ()) == 0)
+ break;
+
+ if (indx == conn.length())
+ conn.length(indx + 1);
conn[indx].name= CORBA::string_dup (plan.connection[i].name.in());
conn[indx].endpoint.length(1L);
conn[indx].endpoint[0] = obj;
@@ -623,9 +631,9 @@ namespace DAnCE
}
catch (...)
{
- DANCE_ERROR (1, (LM_ERROR, DLINFO
- ACE_TEXT("Plan_Launcher_i::create_external_connections - ")
- ACE_TEXT("Caught C++ Exception while resolving endpoint for connection\n")));
+ DANCE_ERROR (1, (LM_ERROR, DLINFO
+ ACE_TEXT("Plan_Launcher_i::create_external_connections - ")
+ ACE_TEXT("Caught C++ Exception while resolving endpoint for connection\n")));
}
}
}