[openrtm-commit:03217] r3235 - branches/RELENG_1_2/OpenRTM-aist/src/lib/rtm

openrtm @ openrtm.org openrtm @ openrtm.org
2018年 3月 5日 (月) 16:52:37 JST


Author: miyamoto
Date: 2018-03-05 16:52:37 +0900 (Mon, 05 Mar 2018)
New Revision: 3235

Modified:
   branches/RELENG_1_2/OpenRTM-aist/src/lib/rtm/Manager.cpp
Log:
[bugfix, ->trunk] bug fixed.

Modified: branches/RELENG_1_2/OpenRTM-aist/src/lib/rtm/Manager.cpp
===================================================================
--- branches/RELENG_1_2/OpenRTM-aist/src/lib/rtm/Manager.cpp	2018-03-05 06:07:30 UTC (rev 3234)
+++ branches/RELENG_1_2/OpenRTM-aist/src/lib/rtm/Manager.cpp	2018-03-05 07:52:37 UTC (rev 3235)
@@ -2598,12 +2598,12 @@
 		  RTObject_impl* comp0 = NULL;
 		  RTC::RTObject_ptr comp0_ref = NULL;
 
-		  if (comp0_name.find("://") == -1)
+		  if (comp0_name.find("://") == std::string::npos)
 		  {
 			  comp0 = getComponent(comp0_name.c_str());
 			  if (comp0 == NULL)
 			  {
-				  RTC_ERROR(("%s not found.", comp0_name));
+				  RTC_ERROR(("%s not found.", comp0_name.c_str()));
 				  continue;
 			  }
 			  comp0_ref = comp0->getObjRef();
@@ -2613,7 +2613,7 @@
 			  RTC::RTCList rtcs = m_namingManager->string_to_component(comp0_name);
 			  if (rtcs.length() == 0)
 			  {
-				  RTC_ERROR(("%s not found.", comp0_name));
+				  RTC_ERROR(("%s not found.", comp0_name.c_str()));
 				  continue;
 			  }
 			  comp0_ref = rtcs[0];
@@ -2627,7 +2627,7 @@
 
 		  if (CORBA::is_nil(port0_var))
 		  {
-			  RTC_DEBUG(("port %s found: ", port0_str));
+			  RTC_DEBUG(("port %s found: ", port0_str.c_str()));
 			  continue;
 		  }
 
@@ -2644,12 +2644,12 @@
 			  RTC::RTObject_ptr comp_ref = NULL;
 
 
-			  if (comp_name.find("://") == -1)
+			  if (comp_name.find("://") == std::string::npos)
 			  {
 				  comp = getComponent(comp_name.c_str());
 				  if (comp == NULL)
 				  {
-					  RTC_ERROR(("%s not found.", comp_name));
+					  RTC_ERROR(("%s not found.", comp_name.c_str()));
 					  continue;
 				  }
 				  comp_ref = comp->getObjRef();
@@ -2659,7 +2659,7 @@
 				  RTC::RTCList rtcs = m_namingManager->string_to_component(comp_name);
 				  if (rtcs.length() == 0)
 				  {
-					  RTC_ERROR(("%s not found.", comp_name));
+					  RTC_ERROR(("%s not found.", comp_name.c_str()));
 					  continue;
 				  }
 				  comp_ref = rtcs[0];
@@ -2673,7 +2673,7 @@
 
 			  if (CORBA::is_nil(port_var))
 			  {
-				  RTC_DEBUG(("port %s found: ", port_str));
+				  RTC_DEBUG(("port %s found: ", port_str.c_str()));
 				  continue;
 			  }
 
@@ -2692,7 +2692,7 @@
 
 			  if (RTC::RTC_OK != CORBA_RTCUtil::connect(connectors[i], prop, port0_var, port_var))
 			  {
-				  RTC_ERROR(("Connection error: %s", connectors[i]));
+				  RTC_ERROR(("Connection error: %s", connectors[i].c_str()));
 			  }
 		  }
 	  }



More information about the openrtm-commit mailing list