[openrtm-commit:02728] r993 - in trunk/OpenRTM-aist-Java/jp.go.aist.rtm.RTC/src/jp/go/aist/rtm/RTC: SDOPackage util
openrtm @ openrtm.org
openrtm @ openrtm.org
2017年 8月 8日 (火) 14:05:16 JST
Author: t-katami
Date: 2017-08-08 14:05:16 +0900 (Tue, 08 Aug 2017)
New Revision: 993
Modified:
trunk/OpenRTM-aist-Java/jp.go.aist.rtm.RTC/src/jp/go/aist/rtm/RTC/SDOPackage/Configuration_impl.java
trunk/OpenRTM-aist-Java/jp.go.aist.rtm.RTC/src/jp/go/aist/rtm/RTC/util/Timer.java
Log:
[compat,bugfix,->RELENG_1_2] Fixed the items pointed out by the static code analysis tool.
Modified: trunk/OpenRTM-aist-Java/jp.go.aist.rtm.RTC/src/jp/go/aist/rtm/RTC/SDOPackage/Configuration_impl.java
===================================================================
--- trunk/OpenRTM-aist-Java/jp.go.aist.rtm.RTC/src/jp/go/aist/rtm/RTC/SDOPackage/Configuration_impl.java 2017-08-08 04:04:56 UTC (rev 992)
+++ trunk/OpenRTM-aist-Java/jp.go.aist.rtm.RTC/src/jp/go/aist/rtm/RTC/SDOPackage/Configuration_impl.java 2017-08-08 05:05:16 UTC (rev 993)
@@ -950,7 +950,6 @@
public final DeviceProfile getDeviceProfile() {
rtcout.println(Logbuf.TRACE, "Configuration_impl.getDeviceProfile()");
-System.out.println("Configuration_impl.getDeviceProfile()");
synchronized(m_deviceProfile){
return m_deviceProfile;
Modified: trunk/OpenRTM-aist-Java/jp.go.aist.rtm.RTC/src/jp/go/aist/rtm/RTC/util/Timer.java
===================================================================
--- trunk/OpenRTM-aist-Java/jp.go.aist.rtm.RTC/src/jp/go/aist/rtm/RTC/util/Timer.java 2017-08-08 04:04:56 UTC (rev 992)
+++ trunk/OpenRTM-aist-Java/jp.go.aist.rtm.RTC/src/jp/go/aist/rtm/RTC/util/Timer.java 2017-08-08 05:05:16 UTC (rev 993)
@@ -44,7 +44,7 @@
* {@.en Processing at cycle of timer}
* <p>
* {@.ja invokeを起動する。}
- * {@.en Starts invoke(). }
+ * {@.en Starts invoke().}
*
* @return
* {@.ja 処理結果
@@ -55,7 +55,12 @@
* At abnormal generation:Throws out the exception.}
*/
public int svc() {
- while(m_running) {
+ while(true) {
+ synchronized (m_running_mutex) {
+ if(!m_running) {
+ break;
+ }
+ }
try {
invoke();
if( m_interval.getSec() != 0) {
@@ -187,6 +192,7 @@
/**
* <p>タイマー実行フラグ</p>
*/
+ private final Object m_running_mutex = new Object();
private boolean m_running;
/**
* <p>タイマー処理登録用クラス</p>
More information about the openrtm-commit
mailing list