Skip to content
体验新版
项目
组织
正在加载...
登录
切换导航
打开侧边栏
LinuxSuRen
jenkins
提交
befe5fcc
J
jenkins
项目概览
LinuxSuRen
/
jenkins
与 Fork 源项目一致
从无法访问的项目Fork
通知
2
Star
0
Fork
0
代码
文件
提交
分支
Tags
贡献者
分支图
Diff
Issue
0
列表
看板
标记
里程碑
合并请求
0
Wiki
0
Wiki
分析
仓库
DevOps
项目成员
Pages
J
jenkins
项目概览
项目概览
详情
发布
仓库
仓库
文件
提交
分支
标签
贡献者
分支图
比较
Issue
0
Issue
0
列表
看板
标记
里程碑
合并请求
0
合并请求
0
Pages
分析
分析
仓库分析
DevOps
Wiki
0
Wiki
成员
成员
收起侧边栏
关闭侧边栏
动态
分支图
创建新Issue
提交
Issue看板
前往新版Gitcode,体验更适合开发者的 AI 搜索 >>
未验证
提交
befe5fcc
编写于
8月 23, 2019
作者:
O
Oleg Nenashev
提交者:
GitHub
8月 23, 2019
浏览文件
操作
浏览文件
下载
差异文件
Merge pull request #4131 from StefanSpieker/JENKINS-36720
JENKINS-36720: Fixed some spotbugs findings
上级
d5292d91
1ea081cd
变更
7
隐藏空白更改
内联
并排
Showing
7 changed file
with
19 addition
and
8 deletion
+19
-8
core/src/main/java/hudson/ExtensionComponent.java
core/src/main/java/hudson/ExtensionComponent.java
+2
-2
core/src/main/java/hudson/cli/SetBuildDescriptionCommand.java
.../src/main/java/hudson/cli/SetBuildDescriptionCommand.java
+4
-0
core/src/main/java/hudson/model/FileParameterValue.java
core/src/main/java/hudson/model/FileParameterValue.java
+1
-0
core/src/main/java/hudson/model/HealthReport.java
core/src/main/java/hudson/model/HealthReport.java
+2
-0
core/src/main/java/hudson/model/JDK.java
core/src/main/java/hudson/model/JDK.java
+1
-0
core/src/main/java/hudson/security/HudsonAuthenticationEntryPoint.java
.../java/hudson/security/HudsonAuthenticationEntryPoint.java
+5
-5
core/src/test/java/hudson/model/TaskActionTest.java
core/src/test/java/hudson/model/TaskActionTest.java
+4
-1
未找到文件。
core/src/main/java/hudson/ExtensionComponent.java
浏览文件 @
befe5fcc
...
...
@@ -88,8 +88,8 @@ public class ExtensionComponent<T> implements Comparable<ExtensionComponent<T>>
public
int
compareTo
(
ExtensionComponent
<
T
>
that
)
{
double
a
=
this
.
ordinal
();
double
b
=
that
.
ordinal
();
if
(
a
>
b
)
return
-
1
;
if
(
a
<
b
)
return
1
;
if
(
Double
.
compare
(
a
,
b
)
>
0
)
return
-
1
;
if
(
Double
.
compare
(
a
,
b
)
<
0
)
return
1
;
// make the order bit more deterministic among extensions of the same ordinal
if
(
this
.
instance
instanceof
Descriptor
&&
that
.
instance
instanceof
Descriptor
)
{
...
...
core/src/main/java/hudson/cli/SetBuildDescriptionCommand.java
浏览文件 @
befe5fcc
package
hudson.cli
;
import
edu.umd.cs.findbugs.annotations.SuppressFBWarnings
;
import
hudson.Extension
;
import
hudson.model.Job
;
import
hudson.model.Run
;
...
...
@@ -9,6 +10,9 @@ import java.io.Serializable;
import
org.apache.commons.io.IOUtils
;
import
org.kohsuke.args4j.Argument
;
// TODO: Remove Serializable
@SuppressFBWarnings
(
value
=
"SE_NO_SERIALVERSIONID"
,
justification
=
"The Serializable should be removed."
)
@Extension
public
class
SetBuildDescriptionCommand
extends
CLICommand
implements
Serializable
{
...
...
core/src/main/java/hudson/model/FileParameterValue.java
浏览文件 @
befe5fcc
...
...
@@ -67,6 +67,7 @@ import org.kohsuke.stapler.StaplerResponse;
public
class
FileParameterValue
extends
ParameterValue
{
private
static
final
String
FOLDER_NAME
=
"fileParameters"
;
private
static
final
Pattern
PROHIBITED_DOUBLE_DOT
=
Pattern
.
compile
(
".*[\\\\/]\\.\\.[\\\\/].*"
);
private
static
final
long
serialVersionUID
=
-
143427023159076073L
;
/**
* Escape hatch for SECURITY-1074, fileParameter used to escape their expected folder.
...
...
core/src/main/java/hudson/model/HealthReport.java
浏览文件 @
befe5fcc
...
...
@@ -63,6 +63,8 @@ public class HealthReport implements Serializable, Comparable<HealthReport> {
private
static
final
String
HEALTH_UNKNOWN_IMG
=
"empty.png"
;
private
static
final
Map
<
String
,
String
>
iconIMGToClassMap
=
new
HashMap
<>();
private
static
final
long
serialVersionUID
=
7451361788415642230L
;
static
{
iconIMGToClassMap
.
put
(
HEALTH_OVER_80_IMG
,
HEALTH_OVER_80
);
iconIMGToClassMap
.
put
(
HEALTH_61_TO_80_IMG
,
HEALTH_61_TO_80
);
...
...
core/src/main/java/hudson/model/JDK.java
浏览文件 @
befe5fcc
...
...
@@ -64,6 +64,7 @@ public final class JDK extends ToolInstallation implements NodeSpecific<JDK>, En
* @since 1.577
*/
public
static
final
String
DEFAULT_NAME
=
"(System)"
;
private
static
final
long
serialVersionUID
=
-
3318291200160313357L
;
@Restricted
(
NoExternalUse
.
class
)
public
static
boolean
isDefaultName
(
String
name
)
{
...
...
core/src/main/java/hudson/security/HudsonAuthenticationEntryPoint.java
浏览文件 @
befe5fcc
...
...
@@ -105,16 +105,16 @@ public class HudsonAuthenticationEntryPoint extends AuthenticationProcessingFilt
"<meta http-equiv='refresh' content='1;url=%1$s'/>"
+
"<script>window.location.replace('%1$s');</script>"
+
"</head>"
+
"<body style='background-color:white; color:white;'>
\
n"
+
"
\n\
n"
+
"Authentication required
\
n"
+
"<!--
\
n"
,
loginForm
);
"<body style='background-color:white; color:white;'>
%
n"
+
"
%n%
n"
+
"Authentication required
%
n"
+
"<!--
%
n"
,
loginForm
);
if
(
cause
!=
null
)
cause
.
report
(
out
);
out
.
printf
(
"-->
\n\
n"
+
"-->
%n%
n"
+
"</body></html>"
);
// Turn Off "Show Friendly HTTP Error Messages" Feature on the Server Side.
// See http://support.microsoft.com/kb/294807
...
...
core/src/test/java/hudson/model/TaskActionTest.java
浏览文件 @
befe5fcc
package
hudson.model
;
import
static
org
.
junit
.
Assert
.
assertEquals
;
import
static
org
.
junit
.
Assert
.
assertTrue
;
import
java.io.ByteArrayOutputStream
;
...
...
@@ -58,7 +59,9 @@ public class TaskActionTest {
Thread
.
sleep
(
10
);
}
ByteArrayOutputStream
os
=
new
ByteArrayOutputStream
();
annotatedText
.
writeLogTo
(
0
,
os
);
final
long
length
=
annotatedText
.
writeLogTo
(
0
,
os
);
// Windows based systems will be 220, linux base 219
assertTrue
(
"length should be longer or even 219"
,
length
>=
219
);
assertTrue
(
os
.
toString
(
"UTF-8"
).
startsWith
(
"a linkCompleted"
));
}
}
编辑
预览
Markdown
is supported
0%
请重试
或
添加新附件
.
添加附件
取消
You are about to add
0
people
to the discussion. Proceed with caution.
先完成此消息的编辑!
取消
想要评论请
注册
或
登录