[openrtm-commit:02765] r1024 - in branches/RELENG_1_2/OpenRTM-aist-Java/jp.go.aist.rtm.RTC/src/jp/go/aist/rtm/RTC: . log util
openrtm @ openrtm.org
openrtm @ openrtm.org
2017年 8月 25日 (金) 15:10:09 JST
Author: t-katami
Date: 2017-08-25 15:10:09 +0900 (Fri, 25 Aug 2017)
New Revision: 1024
Modified:
branches/RELENG_1_2/OpenRTM-aist-Java/jp.go.aist.rtm.RTC/src/jp/go/aist/rtm/RTC/Manager.java
branches/RELENG_1_2/OpenRTM-aist-Java/jp.go.aist.rtm.RTC/src/jp/go/aist/rtm/RTC/ManagerServant.java
branches/RELENG_1_2/OpenRTM-aist-Java/jp.go.aist.rtm.RTC/src/jp/go/aist/rtm/RTC/ModuleManager.java
branches/RELENG_1_2/OpenRTM-aist-Java/jp.go.aist.rtm.RTC/src/jp/go/aist/rtm/RTC/NamingOnCorba.java
branches/RELENG_1_2/OpenRTM-aist-Java/jp.go.aist.rtm.RTC/src/jp/go/aist/rtm/RTC/log/Logbuf.java
branches/RELENG_1_2/OpenRTM-aist-Java/jp.go.aist.rtm.RTC/src/jp/go/aist/rtm/RTC/util/CORBA_SeqUtil.java
Log:
[merge] r982-984 have been merged from trunk
Modified: branches/RELENG_1_2/OpenRTM-aist-Java/jp.go.aist.rtm.RTC/src/jp/go/aist/rtm/RTC/Manager.java
===================================================================
--- branches/RELENG_1_2/OpenRTM-aist-Java/jp.go.aist.rtm.RTC/src/jp/go/aist/rtm/RTC/Manager.java 2017-08-22 01:56:56 UTC (rev 1023)
+++ branches/RELENG_1_2/OpenRTM-aist-Java/jp.go.aist.rtm.RTC/src/jp/go/aist/rtm/RTC/Manager.java 2017-08-25 06:10:09 UTC (rev 1024)
@@ -168,24 +168,22 @@
*/
public static Manager init(String[] argv) {
- if (manager == null) {
- synchronized (manager_mutex) {
- if (manager == null) {
- try {
- manager = new Manager();
- manager.initManager(argv);
- manager.initLogger();
- manager.initORB();
- manager.initNaming();
- manager.initFactories();
- manager.initExecContext();
- manager.initComposite();
- manager.initTimer();
- manager.initManagerServant();
-
- } catch (Exception e) {
- manager = null;
- }
+ synchronized (manager_mutex) {
+ if (manager == null) {
+ try {
+ manager = new Manager();
+ manager.initManager(argv);
+ manager.initLogger();
+ manager.initORB();
+ manager.initNaming();
+ manager.initFactories();
+ manager.initExecContext();
+ manager.initComposite();
+ manager.initTimer();
+ manager.initManagerServant();
+
+ } catch (Exception e) {
+ manager = null;
}
}
}
@@ -212,23 +210,21 @@
*/
public static Manager instance() {
- if (manager == null) {
- synchronized (manager_mutex) {
- if (manager == null) {
- try {
- manager = new Manager();
- manager.initManager(null);
- manager.initLogger();
- manager.initORB();
- manager.initNaming();
- manager.initFactories();
- manager.initExecContext();
- manager.initComposite();
- manager.initTimer();
-
- } catch (Exception e) {
- manager = null;
- }
+ synchronized (manager_mutex) {
+ if (manager == null) {
+ try {
+ manager = new Manager();
+ manager.initManager(null);
+ manager.initLogger();
+ manager.initORB();
+ manager.initNaming();
+ manager.initFactories();
+ manager.initExecContext();
+ manager.initComposite();
+ manager.initTimer();
+
+ } catch (Exception e) {
+ manager = null;
}
}
}
@@ -606,7 +602,7 @@
+ bl.value[ic].binding_name[0].kind;
//String nspath = "/" + nsname + "/" + tmp;
String nspath = nsname + "/" + tmp;
- nspath.replace("\\","");
+ nspath = nspath.replace("\\","");
Object obj;
try {
@@ -1145,15 +1141,16 @@
private void initPreActivation() {
String preactivation
= m_config.getProperty("manager.components.preactivation");
- rtcout.println(Logbuf.TRACE,
- "Components pre-activation: "
- + Arrays.toString(preactivation.split(",")));
String[] comps = new String[0];
if ( preactivation == null || preactivation.length() == 0 ) {
+ rtcout.println(Logbuf.TRACE,
+ "There are no pre-activation components." );
+ return;
}
- else {
- comps = preactivation.split(",");
- }
+ rtcout.println(Logbuf.TRACE,
+ "Components pre-activation: "
+ + Arrays.toString(preactivation.split(",")));
+ comps = preactivation.split(",");
for (int ic=0; ic < comps.length; ++ic) {
comps[ic] = comps[ic].trim();
@@ -1178,17 +1175,11 @@
ReturnCode_t ret = CORBA_RTCUtil.activate(comp_ref);
if (ret != ReturnCode_t.RTC_OK) {
rtcout.println(Logbuf.ERROR, comps[ic] + " activation filed.");
+ continue;
}
else {
rtcout.println(Logbuf.INFO, comps[ic] + " activated.");
}
-/*
- ExecutionContextListHolder eclistholder
- = new ExecutionContextListHolder();
- eclistholder.value = new ExecutionContext[0];
- eclistholder.value = comp.get_owned_contexts();
- eclistholder.value[0].activate_component(comp_ref);
-*/
}
}
}
Modified: branches/RELENG_1_2/OpenRTM-aist-Java/jp.go.aist.rtm.RTC/src/jp/go/aist/rtm/RTC/ManagerServant.java
===================================================================
--- branches/RELENG_1_2/OpenRTM-aist-Java/jp.go.aist.rtm.RTC/src/jp/go/aist/rtm/RTC/ManagerServant.java 2017-08-22 01:56:56 UTC (rev 1023)
+++ branches/RELENG_1_2/OpenRTM-aist-Java/jp.go.aist.rtm.RTC/src/jp/go/aist/rtm/RTC/ManagerServant.java 2017-08-25 06:10:09 UTC (rev 1024)
@@ -1017,6 +1017,7 @@
*/
public ReturnCode_t remove_slave_manager(RTM.Manager mgr) {
if(mgr == null){
+ return ReturnCode_t.BAD_PARAMETER;
}
synchronized(m_masterMutex) {
rtcout.println(Logbuf.TRACE,
Modified: branches/RELENG_1_2/OpenRTM-aist-Java/jp.go.aist.rtm.RTC/src/jp/go/aist/rtm/RTC/ModuleManager.java
===================================================================
--- branches/RELENG_1_2/OpenRTM-aist-Java/jp.go.aist.rtm.RTC/src/jp/go/aist/rtm/RTC/ModuleManager.java 2017-08-22 01:56:56 UTC (rev 1023)
+++ branches/RELENG_1_2/OpenRTM-aist-Java/jp.go.aist.rtm.RTC/src/jp/go/aist/rtm/RTC/ModuleManager.java 2017-08-25 06:10:09 UTC (rev 1024)
@@ -631,7 +631,7 @@
}
}
else{
- String str[] = dlls.elementAt(ic).split(".class");
+ String str[] = dlls.elementAt(ic).split("\\.class");
str[0] = str[0].replace(separator,".");
str[0] = str[0].replace("..",".");
try {
Modified: branches/RELENG_1_2/OpenRTM-aist-Java/jp.go.aist.rtm.RTC/src/jp/go/aist/rtm/RTC/NamingOnCorba.java
===================================================================
--- branches/RELENG_1_2/OpenRTM-aist-Java/jp.go.aist.rtm.RTC/src/jp/go/aist/rtm/RTC/NamingOnCorba.java 2017-08-22 01:56:56 UTC (rev 1023)
+++ branches/RELENG_1_2/OpenRTM-aist-Java/jp.go.aist.rtm.RTC/src/jp/go/aist/rtm/RTC/NamingOnCorba.java 2017-08-25 06:10:09 UTC (rev 1024)
@@ -295,9 +295,11 @@
else{
Manager mgr = Manager.instance();
if(mgr==null){
+ return null;
}
ORB orb = mgr.getORB();
if(orb==null){
+ return null;
}
cns = new CorbaNaming(orb,host);
}
Modified: branches/RELENG_1_2/OpenRTM-aist-Java/jp.go.aist.rtm.RTC/src/jp/go/aist/rtm/RTC/log/Logbuf.java
===================================================================
--- branches/RELENG_1_2/OpenRTM-aist-Java/jp.go.aist.rtm.RTC/src/jp/go/aist/rtm/RTC/log/Logbuf.java 2017-08-22 01:56:56 UTC (rev 1023)
+++ branches/RELENG_1_2/OpenRTM-aist-Java/jp.go.aist.rtm.RTC/src/jp/go/aist/rtm/RTC/log/Logbuf.java 2017-08-25 06:10:09 UTC (rev 1024)
@@ -115,7 +115,7 @@
}
String str;
- if((parent.length() == 0) || (parent == null)) {
+ if((parent == null) || (parent.length() == 0)) {
str = "OpenRTM-aist.logging." + name;
} else {
str = "OpenRTM-aist.logging." + parent + "." + name;
Modified: branches/RELENG_1_2/OpenRTM-aist-Java/jp.go.aist.rtm.RTC/src/jp/go/aist/rtm/RTC/util/CORBA_SeqUtil.java
===================================================================
--- branches/RELENG_1_2/OpenRTM-aist-Java/jp.go.aist.rtm.RTC/src/jp/go/aist/rtm/RTC/util/CORBA_SeqUtil.java 2017-08-22 01:56:56 UTC (rev 1023)
+++ branches/RELENG_1_2/OpenRTM-aist-Java/jp.go.aist.rtm.RTC/src/jp/go/aist/rtm/RTC/util/CORBA_SeqUtil.java 2017-08-25 06:10:09 UTC (rev 1024)
@@ -997,7 +997,7 @@
} else {
len = seq.value.length;
}
- if (index > len) {
+ if((index > len)||(len == 0)) {
push_back(seq, elem);
return;
}
More information about the openrtm-commit
mailing list