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
a13666d6
Commit
a13666d6
authored
Sep 27, 2019
by
Phillip Webb
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Polish "Simplify code"
See gh-18342
parent
4d0da4b7
Changes
2
Hide whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
3 additions
and
4 deletions
+3
-4
BootArchiveSupport.java
...mework/boot/gradle/tasks/bundling/BootArchiveSupport.java
+2
-2
TomcatServletWebServerFactoryTests.java
...b/embedded/tomcat/TomcatServletWebServerFactoryTests.java
+1
-2
No files found.
spring-boot-project/spring-boot-tools/spring-boot-gradle-plugin/src/main/java/org/springframework/boot/gradle/tasks/bundling/BootArchiveSupport.java
View file @
a13666d6
...
...
@@ -143,8 +143,8 @@ class BootArchiveSupport {
}
private
boolean
isZip
(
InputStream
inputStream
)
throws
IOException
{
for
(
byte
b
:
ZIP_FILE_HEADER
)
{
if
(
inputStream
.
read
()
!=
b
)
{
for
(
byte
headerByte
:
ZIP_FILE_HEADER
)
{
if
(
inputStream
.
read
()
!=
headerByte
)
{
return
false
;
}
}
...
...
spring-boot-project/spring-boot/src/test/java/org/springframework/boot/web/embedded/tomcat/TomcatServletWebServerFactoryTests.java
View file @
a13666d6
...
...
@@ -68,7 +68,6 @@ import org.mockito.InOrder;
import
org.springframework.boot.testsupport.system.CapturedOutput
;
import
org.springframework.boot.web.server.PortInUseException
;
import
org.springframework.boot.web.server.WebServerException
;
import
org.springframework.boot.web.servlet.ServletContextInitializer
;
import
org.springframework.boot.web.servlet.server.AbstractServletWebServerFactory
;
import
org.springframework.boot.web.servlet.server.AbstractServletWebServerFactoryTests
;
import
org.springframework.core.io.ByteArrayResource
;
...
...
@@ -544,7 +543,7 @@ class TomcatServletWebServerFactoryTests extends AbstractServletWebServerFactory
@Test
void
registerJspServletWithDefaultLoadOnStartup
()
{
TomcatServletWebServerFactory
factory
=
new
TomcatServletWebServerFactory
(
0
);
factory
.
addInitializers
(
servletContext
->
servletC
ontext
.
addServlet
(
"manually-registered-jsp-servlet"
,
JspServlet
.
class
));
factory
.
addInitializers
(
(
context
)
->
c
ontext
.
addServlet
(
"manually-registered-jsp-servlet"
,
JspServlet
.
class
));
this
.
webServer
=
factory
.
getWebServer
();
this
.
webServer
.
start
();
}
...
...
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