Commit 8cab031c authored by 赵啸非's avatar 赵啸非

修改登录鉴权时间

parent b3002524
...@@ -122,10 +122,12 @@ public class ZipUtils { ...@@ -122,10 +122,12 @@ public class ZipUtils {
// 解压tar包 // 解压tar包
public Set<String> unTar(String fileName, String unZipPath) { public Set<String> unTar(String fileName, String unZipPath) {
Set<String> set = new HashSet<>(); Set<String> set = new HashSet<>();
InputStream inputStream =null;
TarArchiveInputStream fin =null;
try { try {
InputStream inputStream = FileUtil.getInputStream(fileName); inputStream = FileUtil.getInputStream(fileName);
TarArchiveInputStream fin = new TarArchiveInputStream(inputStream); fin = new TarArchiveInputStream(inputStream);
log.info("********开始执行tar"); log.info("********开始执行tar");
// File extraceFolder = new File(unZipPath); // File extraceFolder = new File(unZipPath);
TarArchiveEntry entry; TarArchiveEntry entry;
...@@ -154,7 +156,18 @@ public class ZipUtils { ...@@ -154,7 +156,18 @@ public class ZipUtils {
} catch (IOException e) { } catch (IOException e) {
e.printStackTrace(); log.error("解压tar文件失败", e);
}finally {
try {
fin.close();
} catch (IOException e) {
throw new RuntimeException(e);
}
try {
inputStream.close();
} catch (IOException e) {
throw new RuntimeException(e);
}
} }
if (localFiles == null) { if (localFiles == null) {
localFiles = set; localFiles = set;
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment