[openrtm-commit:03328] r1129 - trunk/OpenRTM-aist-Java/jp.go.aist.rtm.RTC/src/jp/go/aist/rtm/RTC

openrtm @ openrtm.org openrtm @ openrtm.org
2018年 3月 30日 (金) 17:13:42 JST


Author: t-katami
Date: 2018-03-30 17:13:42 +0900 (Fri, 30 Mar 2018)
New Revision: 1129

Modified:
   trunk/OpenRTM-aist-Java/jp.go.aist.rtm.RTC/src/jp/go/aist/rtm/RTC/ModuleManager.java
Log:
[compat,bugfix,->RELENG_1_2] Fixed the bug. refs #4499

Modified: trunk/OpenRTM-aist-Java/jp.go.aist.rtm.RTC/src/jp/go/aist/rtm/RTC/ModuleManager.java
===================================================================
--- trunk/OpenRTM-aist-Java/jp.go.aist.rtm.RTC/src/jp/go/aist/rtm/RTC/ModuleManager.java	2018-03-30 05:15:38 UTC (rev 1128)
+++ trunk/OpenRTM-aist-Java/jp.go.aist.rtm.RTC/src/jp/go/aist/rtm/RTC/ModuleManager.java	2018-03-30 08:13:42 UTC (rev 1129)
@@ -1203,10 +1203,17 @@
             while(!stack.isEmpty()){
                 File item = stack.pop();
                 if (item.isDirectory()) {
-                    result.add(item.getPath());
-                    for (File child : item.listFiles()){
-                        stack.push(child);
+                    String str = item.getPath();
+                    String osname = System.getProperty("os.name").toLowerCase();
+                    if(osname.startsWith("windows")){
+                        str = str.replace("\\","/");
                     }
+                    if(result.indexOf(str)==-1){
+                        result.add(str);
+                        for (File child : item.listFiles()){
+                            stack.push(child);
+                        }
+                    }
                 }
             }
         }



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