[openrtm-commit:02582] r814 - trunk/OpenRTM-aist-Python/OpenRTM_aist

openrtm @ openrtm.org openrtm @ openrtm.org
2017年 4月 17日 (月) 16:23:30 JST


Author: miyamoto
Date: 2017-04-17 16:23:30 +0900 (Mon, 17 Apr 2017)
New Revision: 814

Modified:
   trunk/OpenRTM-aist-Python/OpenRTM_aist/ManagerServant.py
Log:
[compat,bugfix,->RELENG_1_2] fixed bug.

Modified: trunk/OpenRTM-aist-Python/OpenRTM_aist/ManagerServant.py
===================================================================
--- trunk/OpenRTM-aist-Python/OpenRTM_aist/ManagerServant.py	2017-04-12 07:02:05 UTC (rev 813)
+++ trunk/OpenRTM-aist-Python/OpenRTM_aist/ManagerServant.py	2017-04-17 07:23:30 UTC (rev 814)
@@ -21,6 +21,7 @@
 from omniORB import CORBA
 import OpenRTM_aist
 import RTC,RTM,RTM__POA
+import platform
 
 
 
@@ -290,6 +291,7 @@
   #
   # RTObject_ptr create_component(const char* module_name)
   def create_component(self, module_name):
+    
     self._rtcout.RTC_TRACE("create_component(%s)", module_name)
 
     
@@ -304,6 +306,7 @@
     
 
 
+    module_name = module_name.split("&")[0]
     
     if self._isMaster:
       guard = OpenRTM_aist.ScopedLock(self._slaveMutex)
@@ -1131,8 +1134,10 @@
       if not rtcd_cmd:
         rtcd_cmd = "rtcd_python"
       #rtcd_cmd = "rtcd_python.bat"
-      
-      cmd = rtcd_cmd
+      if platform.system() == "Windows":
+        cmd = "cmd /c " + rtcd_cmd
+      else:
+        cmd = rtcd_cmd
       cmd += " -o " + "manager.is_master:NO"
       cmd += " -o " + "manager.corba_servant:YES"
       cmd += " -o " + "corba.master_manager:" + config.getProperty("corba.master_manager")
@@ -1143,6 +1148,7 @@
       
       
       self._rtcout.RTC_DEBUG("Invoking command: %s.", cmd)
+      
       ret = OpenRTM_aist.launch_shell(cmd)
 
       
@@ -1239,7 +1245,10 @@
         rtcd_cmd = "rtcd_python"
 
 
-      cmd = rtcd_cmd
+      if platform.system() == "Windows":
+        cmd = "cmd /c " + rtcd_cmd
+      else:
+        cmd = rtcd_cmd
       cmd += " -o corba.master_manager:"
       cmd += mgrstr # port number
       cmd += " -d "



openrtm-commit メーリングリストの案内