mirror of
https://github.com/jenkinsci/jenkins.git
synced 2026-11-08 01:26:03 +00:00
Optimize and close Zip resources in ClassicPluginStrategy and FilePath
This commit is contained in:
1 parent
3835b3fcc7
commit
f5742df16b
2 files changed
+35
-25
No files matched your search
@@ -527,7 +527,12 @@ public final class FilePath implements Serializable {
|
||||
if (p != null) {
|
||||
p.mkdirs();
|
||||
}
|
||||
IOUtils.copy(zip.getInputStream(e), f);
|
||||
InputStream input = zip.getInputStream(e);
|
||||
try {
|
||||
IOUtils.copy(input, f);
|
||||
} finally {
|
||||
input.close();
|
||||
}
|
||||
try {
|
||||
FilePath target = new FilePath(f);
|
||||
int mode = e.getUnixMode();
|
||||
|
||||
Reference in new issue
Block a user