[openrtm-commit:02076] r728 - trunk/OpenRTM-aist-Python/OpenRTM_aist

openrtm @ openrtm.org openrtm @ openrtm.org
2016年 10月 26日 (水) 19:10:41 JST


Author: miyamoto
Date: 2016-10-26 19:10:41 +0900 (Wed, 26 Oct 2016)
New Revision: 728

Modified:
   trunk/OpenRTM-aist-Python/OpenRTM_aist/CorbaConsumer.py
   trunk/OpenRTM-aist-Python/OpenRTM_aist/InPortCorbaCdrConsumer.py
   trunk/OpenRTM-aist-Python/OpenRTM_aist/OutPortCorbaCdrConsumer.py
Log:
[compat,bugfix,->RELENG_1_2] fixed bug. refs #3408

Modified: trunk/OpenRTM-aist-Python/OpenRTM_aist/CorbaConsumer.py
===================================================================
--- trunk/OpenRTM-aist-Python/OpenRTM_aist/CorbaConsumer.py	2016-10-20 10:37:21 UTC (rev 727)
+++ trunk/OpenRTM-aist-Python/OpenRTM_aist/CorbaConsumer.py	2016-10-26 10:10:41 UTC (rev 728)
@@ -247,7 +247,9 @@
   def __del__(self):
     self.releaseObject()
 
+    
 
+
   ##
   # @if jp
   # @brief オブジェクトをセットする
@@ -316,8 +318,10 @@
   # @return The object reference narrowed as ObjectType
   #
   # @endif
-  def _ptr(self):
+  def _ptr(self, get_ref=False):
     #print dir(self._var)
+    if get_ref:
+      return self._var
     if self._sev is not None:
       return self._sev
     try:

Modified: trunk/OpenRTM-aist-Python/OpenRTM_aist/InPortCorbaCdrConsumer.py
===================================================================
--- trunk/OpenRTM-aist-Python/OpenRTM_aist/InPortCorbaCdrConsumer.py	2016-10-20 10:37:21 UTC (rev 727)
+++ trunk/OpenRTM-aist-Python/OpenRTM_aist/InPortCorbaCdrConsumer.py	2016-10-26 10:10:41 UTC (rev 728)
@@ -376,7 +376,7 @@
     
     orb = OpenRTM_aist.Manager.instance().getORB()
     var = orb.string_to_object(ior)
-    if not self._ptr()._is_equivalent(var):
+    if not self._ptr(True)._is_equivalent(var):
       self._rtcout.RTC_ERROR("connector property inconsistency")
       return False
     
@@ -414,7 +414,7 @@
     if not obj:
       return False
 
-    if not self._ptr()._is_equivalent(obj):
+    if not self._ptr(True)._is_equivalent(obj):
       return False
     
     self.releaseObject()

Modified: trunk/OpenRTM-aist-Python/OpenRTM_aist/OutPortCorbaCdrConsumer.py
===================================================================
--- trunk/OpenRTM-aist-Python/OpenRTM_aist/OutPortCorbaCdrConsumer.py	2016-10-20 10:37:21 UTC (rev 727)
+++ trunk/OpenRTM-aist-Python/OpenRTM_aist/OutPortCorbaCdrConsumer.py	2016-10-26 10:10:41 UTC (rev 728)
@@ -312,7 +312,7 @@
         self._rtcout.RTC_DEBUG("dataport.corba_cdr.outport_ior found.")
         orb = OpenRTM_aist.Manager.instance().getORB()
         obj = orb.string_to_object(ior)
-        if self._ptr()._is_equivalent(obj):
+        if self._ptr(True)._is_equivalent(obj):
           self.releaseObject()
           self._rtcout.RTC_DEBUG("CorbaConsumer's reference was released.")
           return



More information about the openrtm-commit mailing list