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
9540905e
Commit
9540905e
authored
Feb 18, 2019
by
Andy Wilkinson
Browse files
Options
Browse Files
Download
Plain Diff
Merge branch '2.1.x'
parents
ff6ef1e5
68e3de03
Changes
2
Hide whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
6 additions
and
4 deletions
+6
-4
JarEntry.java
...in/java/org/springframework/boot/loader/jar/JarEntry.java
+5
-2
JarFileEntries.java
...a/org/springframework/boot/loader/jar/JarFileEntries.java
+1
-2
No files found.
spring-boot-project/spring-boot-tools/spring-boot-loader/src/main/java/org/springframework/boot/loader/jar/JarEntry.java
View file @
9540905e
/*
/*
* Copyright 2012-201
8
the original author or authors.
* Copyright 2012-201
9
the original author or authors.
*
*
* Licensed under the Apache License, Version 2.0 (the "License");
* Licensed under the Apache License, Version 2.0 (the "License");
* you may not use this file except in compliance with the License.
* you may not use this file except in compliance with the License.
...
@@ -34,6 +34,8 @@ class JarEntry extends java.util.jar.JarEntry implements FileHeader {
...
@@ -34,6 +34,8 @@ class JarEntry extends java.util.jar.JarEntry implements FileHeader {
private
final
AsciiBytes
name
;
private
final
AsciiBytes
name
;
private
final
AsciiBytes
headerName
;
private
Certificate
[]
certificates
;
private
Certificate
[]
certificates
;
private
CodeSigner
[]
codeSigners
;
private
CodeSigner
[]
codeSigners
;
...
@@ -45,6 +47,7 @@ class JarEntry extends java.util.jar.JarEntry implements FileHeader {
...
@@ -45,6 +47,7 @@ class JarEntry extends java.util.jar.JarEntry implements FileHeader {
JarEntry
(
JarFile
jarFile
,
CentralDirectoryFileHeader
header
,
AsciiBytes
nameAlias
)
{
JarEntry
(
JarFile
jarFile
,
CentralDirectoryFileHeader
header
,
AsciiBytes
nameAlias
)
{
super
((
nameAlias
!=
null
)
?
nameAlias
.
toString
()
:
header
.
getName
().
toString
());
super
((
nameAlias
!=
null
)
?
nameAlias
.
toString
()
:
header
.
getName
().
toString
());
this
.
name
=
(
nameAlias
!=
null
)
?
nameAlias
:
header
.
getName
();
this
.
name
=
(
nameAlias
!=
null
)
?
nameAlias
:
header
.
getName
();
this
.
headerName
=
header
.
getName
();
this
.
jarFile
=
jarFile
;
this
.
jarFile
=
jarFile
;
this
.
localHeaderOffset
=
header
.
getLocalHeaderOffset
();
this
.
localHeaderOffset
=
header
.
getLocalHeaderOffset
();
setCompressedSize
(
header
.
getCompressedSize
());
setCompressedSize
(
header
.
getCompressedSize
());
...
@@ -62,7 +65,7 @@ class JarEntry extends java.util.jar.JarEntry implements FileHeader {
...
@@ -62,7 +65,7 @@ class JarEntry extends java.util.jar.JarEntry implements FileHeader {
@Override
@Override
public
boolean
hasName
(
CharSequence
name
,
char
suffix
)
{
public
boolean
hasName
(
CharSequence
name
,
char
suffix
)
{
return
this
.
n
ame
.
matches
(
name
,
suffix
);
return
this
.
headerN
ame
.
matches
(
name
,
suffix
);
}
}
/**
/**
...
...
spring-boot-project/spring-boot-tools/spring-boot-loader/src/main/java/org/springframework/boot/loader/jar/JarFileEntries.java
View file @
9540905e
...
@@ -305,8 +305,7 @@ class JarFileEntries implements CentralDirectoryVisitor, Iterable<JarEntry> {
...
@@ -305,8 +305,7 @@ class JarFileEntries implements CentralDirectoryVisitor, Iterable<JarEntry> {
int
index
=
getFirstIndex
(
hashCode
);
int
index
=
getFirstIndex
(
hashCode
);
while
(
index
>=
0
&&
index
<
this
.
size
&&
this
.
hashCodes
[
index
]
==
hashCode
)
{
while
(
index
>=
0
&&
index
<
this
.
size
&&
this
.
hashCodes
[
index
]
==
hashCode
)
{
T
entry
=
getEntry
(
index
,
type
,
cacheEntry
,
nameAlias
);
T
entry
=
getEntry
(
index
,
type
,
cacheEntry
,
nameAlias
);
if
(
entry
.
hasName
((
nameAlias
!=
null
)
?
nameAlias
.
toString
()
:
name
,
if
(
entry
.
hasName
(
name
,
suffix
))
{
suffix
))
{
return
entry
;
return
entry
;
}
}
index
++;
index
++;
...
...
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