|
@@ -199,8 +199,8 @@ public class RWDDownloadUtil {
|
|
|
SimpleDateFormat sdf = new SimpleDateFormat("yyyyMMddHHmmss");
|
|
|
String validPath = Constant.getLatestPath(Constant.physical_world, true);
|
|
|
// 存储临时文件
|
|
|
- File dir1;
|
|
|
- {
|
|
|
+ File dir1 = null;
|
|
|
+ if (validPath != null) {
|
|
|
String tmpPath = Constant.physical_world + Constant.getSeperator() + "tmp1";
|
|
|
dir1 = new File(tmpPath);
|
|
|
RWDDownloadUtil.Load_physical_world(tmpPath, LogOfDownload);
|
|
@@ -212,7 +212,10 @@ public class RWDDownloadUtil {
|
|
|
RWDDownloadUtil.Load_physical_world(tmpPath, LogOfDownload);
|
|
|
}
|
|
|
// 检查一致性
|
|
|
- boolean compare = FileUtil.compareRecursive(dir1, dir2, null);
|
|
|
+ boolean compare = true;
|
|
|
+ if (validPath != null) {
|
|
|
+ compare = FileUtil.compareRecursive(dir1, dir2, null);
|
|
|
+ }
|
|
|
log.debug("Compare tmp1" + (compare ? "==" : "!=") + "tmp2");
|
|
|
boolean result;
|
|
|
if (compare) {
|
|
@@ -387,8 +390,8 @@ public class RWDDownloadUtil {
|
|
|
SimpleDateFormat sdf = new SimpleDateFormat("yyyyMMddHHmmss");
|
|
|
String validPath = Constant.getLatestPath(Constant.zkt_physical_world, true);
|
|
|
// 存储临时文件
|
|
|
- File dir1;
|
|
|
- {
|
|
|
+ File dir1 = null;
|
|
|
+ if (validPath != null) {
|
|
|
String tmpPath = Constant.zkt_physical_world + Constant.getSeperator() + "tmp1";
|
|
|
dir1 = new File(tmpPath);
|
|
|
RWDDownloadUtil.Load_zkt_physical_world(tmpPath, LogOfDownload);
|
|
@@ -400,7 +403,10 @@ public class RWDDownloadUtil {
|
|
|
RWDDownloadUtil.Load_zkt_physical_world(tmpPath, LogOfDownload);
|
|
|
}
|
|
|
// 检查一致性
|
|
|
- boolean compare = FileUtil.compareRecursive(dir1, dir2, null);
|
|
|
+ boolean compare = true;
|
|
|
+ if (validPath != null) {
|
|
|
+ compare = FileUtil.compareRecursive(dir1, dir2, null);
|
|
|
+ }
|
|
|
log.debug("Compare tmp1" + (compare ? "==" : "!=") + "tmp2");
|
|
|
boolean result;
|
|
|
if (compare) {
|
|
@@ -627,8 +633,8 @@ public class RWDDownloadUtil {
|
|
|
SimpleDateFormat sdf = new SimpleDateFormat("yyyyMMddHHmmss");
|
|
|
String validPath = Constant.getLatestPath(Constant.ibms_physical_world, true);
|
|
|
// 存储临时文件
|
|
|
- File dir1;
|
|
|
- {
|
|
|
+ File dir1 = null;
|
|
|
+ if (validPath != null) {
|
|
|
String tmpPath = Constant.ibms_physical_world + Constant.getSeperator() + "tmp1";
|
|
|
dir1 = new File(tmpPath);
|
|
|
RWDDownloadUtil.Load_ibms_physical_world(tmpPath, LogOfDownload);
|
|
@@ -640,7 +646,10 @@ public class RWDDownloadUtil {
|
|
|
RWDDownloadUtil.Load_ibms_physical_world(tmpPath, LogOfDownload);
|
|
|
}
|
|
|
// 检查一致性
|
|
|
- boolean compare = FileUtil.compareRecursive(dir1, dir2, null);
|
|
|
+ boolean compare = true;
|
|
|
+ if (validPath != null) {
|
|
|
+ compare = FileUtil.compareRecursive(dir1, dir2, null);
|
|
|
+ }
|
|
|
log.debug("Compare tmp1" + (compare ? "==" : "!=") + "tmp2");
|
|
|
boolean result;
|
|
|
if (compare) {
|