Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Submit feedback
Sign in / Register
Toggle navigation
S
spring-boot
Project
Project
Details
Activity
Releases
Cycle Analytics
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Issues
0
Issues
0
List
Board
Labels
Milestones
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Charts
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
DEMO
spring-boot
Commits
1cda557d
Commit
1cda557d
authored
Jun 03, 2021
by
Phillip Webb
Browse files
Options
Browse Files
Download
Plain Diff
Merge branch '2.3.x' into 2.4.x
Closes gh-26743
parents
2ff3fe22
1beee570
Changes
2
Hide whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
16 additions
and
6 deletions
+16
-6
JarFile.java
...ain/java/org/springframework/boot/loader/jar/JarFile.java
+12
-4
JarFileWrapper.java
...a/org/springframework/boot/loader/jar/JarFileWrapper.java
+4
-2
No files found.
spring-boot-project/spring-boot-tools/spring-boot-loader/src/main/java/org/springframework/boot/loader/jar/JarFile.java
View file @
1cda557d
/*
* Copyright 2012-202
0
the original author or authors.
* Copyright 2012-202
1
the original author or authors.
*
* Licensed under the Apache License, Version 2.0 (the "License");
* you may not use this file except in compliance with the License.
...
...
@@ -126,7 +126,9 @@ public class JarFile extends AbstractJarFile implements Iterable<java.util.jar.J
private
JarFile
(
RandomAccessDataFile
rootFile
,
String
pathFromRoot
,
RandomAccessData
data
,
JarEntryFilter
filter
,
JarFileType
type
,
Supplier
<
Manifest
>
manifestSupplier
)
throws
IOException
{
super
(
rootFile
.
getFile
());
super
.
close
();
if
(
System
.
getSecurityManager
()
==
null
)
{
super
.
close
();
}
this
.
rootFile
=
rootFile
;
this
.
pathFromRoot
=
pathFromRoot
;
CentralDirectoryParser
parser
=
new
CentralDirectoryParser
();
...
...
@@ -137,7 +139,12 @@ public class JarFile extends AbstractJarFile implements Iterable<java.util.jar.J
this
.
data
=
parser
.
parse
(
data
,
filter
==
null
);
}
catch
(
RuntimeException
ex
)
{
close
();
try
{
this
.
rootFile
.
close
();
super
.
close
();
}
catch
(
IOException
ioex
)
{
}
throw
ex
;
}
this
.
manifestSupplier
=
(
manifestSupplier
!=
null
)
?
manifestSupplier
:
()
->
{
...
...
@@ -337,10 +344,11 @@ public class JarFile extends AbstractJarFile implements Iterable<java.util.jar.J
if
(
this
.
closed
)
{
return
;
}
this
.
closed
=
true
;
super
.
close
()
;
if
(
this
.
type
==
JarFileType
.
DIRECT
)
{
this
.
rootFile
.
close
();
}
this
.
closed
=
true
;
}
private
void
ensureOpen
()
{
...
...
spring-boot-project/spring-boot-tools/spring-boot-loader/src/main/java/org/springframework/boot/loader/jar/JarFileWrapper.java
View file @
1cda557d
/*
* Copyright 2012-202
0
the original author or authors.
* Copyright 2012-202
1
the original author or authors.
*
* Licensed under the Apache License, Version 2.0 (the "License");
* you may not use this file except in compliance with the License.
...
...
@@ -40,7 +40,9 @@ class JarFileWrapper extends AbstractJarFile {
JarFileWrapper
(
JarFile
parent
)
throws
IOException
{
super
(
parent
.
getRootJarFile
().
getFile
());
this
.
parent
=
parent
;
super
.
close
();
if
(
System
.
getSecurityManager
()
==
null
)
{
super
.
close
();
}
}
@Override
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment