Skip to content
体验新版
项目
组织
正在加载...
登录
切换导航
打开侧边栏
openanolis
dragonwell8_jdk
提交
328a3926
D
dragonwell8_jdk
项目概览
openanolis
/
dragonwell8_jdk
通知
4
Star
2
Fork
0
代码
文件
提交
分支
Tags
贡献者
分支图
Diff
Issue
0
列表
看板
标记
里程碑
合并请求
0
Wiki
0
Wiki
分析
仓库
DevOps
项目成员
Pages
D
dragonwell8_jdk
项目概览
项目概览
详情
发布
仓库
仓库
文件
提交
分支
标签
贡献者
分支图
比较
Issue
0
Issue
0
列表
看板
标记
里程碑
合并请求
0
合并请求
0
Pages
分析
分析
仓库分析
DevOps
Wiki
0
Wiki
成员
成员
收起侧边栏
关闭侧边栏
动态
分支图
创建新Issue
提交
Issue看板
提交
328a3926
编写于
11月 09, 2012
作者:
K
ksrini
浏览文件
操作
浏览文件
下载
电子邮件补丁
差异文件
8002091: tools/launcher/ToolsOpts.java test started to fail since 7u11 b01 on Windows
Reviewed-by: darcy, jjh, mschoene
上级
905387a2
变更
3
隐藏空白更改
内联
并排
Showing
3 changed file
with
26 addition
and
14 deletion
+26
-14
src/share/bin/jli_util.h
src/share/bin/jli_util.h
+1
-1
src/windows/bin/java_md.c
src/windows/bin/java_md.c
+24
-13
test/tools/launcher/ToolsOpts.java
test/tools/launcher/ToolsOpts.java
+1
-0
未找到文件。
src/share/bin/jli_util.h
浏览文件 @
328a3926
...
@@ -66,7 +66,7 @@ int JLI_GetStdArgc();
...
@@ -66,7 +66,7 @@ int JLI_GetStdArgc();
#include <io.h>
#include <io.h>
#define JLI_StrCaseCmp(p1, p2) stricmp((p1), (p2))
#define JLI_StrCaseCmp(p1, p2) stricmp((p1), (p2))
#define JLI_StrNCaseCmp(p1, p2, p3) strnicmp((p1), (p2), (p3))
#define JLI_StrNCaseCmp(p1, p2, p3) strnicmp((p1), (p2), (p3))
size_
t
JLI_Snprintf
(
char
*
buffer
,
size_t
size
,
const
char
*
format
,
...);
in
t
JLI_Snprintf
(
char
*
buffer
,
size_t
size
,
const
char
*
format
,
...);
void
JLI_CmdToArgs
(
char
*
cmdline
);
void
JLI_CmdToArgs
(
char
*
cmdline
);
#define JLI_Lseek _lseeki64
#define JLI_Lseek _lseeki64
#else
/* NIXES */
#else
/* NIXES */
...
...
src/windows/bin/java_md.c
浏览文件 @
328a3926
...
@@ -526,27 +526,35 @@ jlong Counter2Micros(jlong counts)
...
@@ -526,27 +526,35 @@ jlong Counter2Micros(jlong counts)
}
}
return
(
counts
*
1000
*
1000
)
/
counterFrequency
.
QuadPart
;
return
(
counts
*
1000
*
1000
)
/
counterFrequency
.
QuadPart
;
}
}
/*
/*
* windows snprintf does not guarantee a null terminator in the buffer,
* windows snprintf does not guarantee a null terminator in the buffer,
* if the computed size is equal to or greater than the buffer size,
* if the computed size is equal to or greater than the buffer size,
* as well as error conditions, this function guarantees a null terminator
* as well as error conditions. This function guarantees a null terminator
* under all these conditions. An unreasonable buffer size will return
* under all these conditions. An unreasonable buffer or size will return
* an error value.
* an error value. Under all other conditions this function will return the
* size of the bytes actually written minus the null terminator, similar
* to ansi snprintf api. Thus when calling this function the caller must
* ensure storage for the null terminator.
*/
*/
size_t
int
JLI_Snprintf
(
char
*
buffer
,
size_t
size
,
const
char
*
format
,
...)
JLI_Snprintf
(
char
*
buffer
,
size_t
size
,
const
char
*
format
,
...)
{
{
int
rc
;
size_t
rc
;
va_list
vl
;
va_list
vl
;
if
(
size
<=
0
)
if
(
size
==
0
||
buffer
==
NULL
)
return
-
1
;
return
-
1
;
buffer
[
0
]
=
'\0'
;
va_start
(
vl
,
format
);
va_start
(
vl
,
format
);
rc
=
vsnprintf
(
buffer
,
size
-
1
,
format
,
vl
);
rc
=
vsnprintf
(
buffer
,
size
,
format
,
vl
);
va_end
(
vl
);
/* force a null terminator, if something is amiss */
/* force a null terminator, if something is amiss */
if
(
rc
<
0
||
rc
>=
size
)
if
(
rc
<
0
)
{
/* apply ansi semantics */
buffer
[
size
-
1
]
=
'\0'
;
buffer
[
size
-
1
]
=
'\0'
;
va_end
(
vl
);
return
size
;
}
else
if
(
rc
==
size
)
{
/* force a null terminator */
buffer
[
size
-
1
]
=
'\0'
;
}
return
rc
;
return
rc
;
}
}
...
@@ -1441,7 +1449,10 @@ CreateApplicationArgs(JNIEnv *env, char **strv, int argc)
...
@@ -1441,7 +1449,10 @@ CreateApplicationArgs(JNIEnv *env, char **strv, int argc)
// we add the indicator
// we add the indicator
tlen
=
1
+
JLI_StrLen
(
strv
[
i
])
+
1
;
tlen
=
1
+
JLI_StrLen
(
strv
[
i
])
+
1
;
nargv
[
i
]
=
(
char
*
)
JLI_MemAlloc
(
tlen
);
nargv
[
i
]
=
(
char
*
)
JLI_MemAlloc
(
tlen
);
JLI_Snprintf
(
nargv
[
i
],
tlen
,
"%c%s"
,
arg_expand
?
'T'
:
'F'
,
strv
[
i
]);
if
(
JLI_Snprintf
(
nargv
[
i
],
tlen
,
"%c%s"
,
arg_expand
?
'T'
:
'F'
,
strv
[
i
])
<
0
)
{
return
NULL
;
}
JLI_TraceLauncher
(
"%s
\n
"
,
nargv
[
i
]);
JLI_TraceLauncher
(
"%s
\n
"
,
nargv
[
i
]);
}
}
...
...
test/tools/launcher/ToolsOpts.java
浏览文件 @
328a3926
...
@@ -23,6 +23,7 @@
...
@@ -23,6 +23,7 @@
/*
/*
* @test
* @test
* @bug 8002091
* @summary Test options patterns for javac,javah,javap and javadoc using
* @summary Test options patterns for javac,javah,javap and javadoc using
* javac as a test launcher. Create a dummy javac and intercept options to check
* javac as a test launcher. Create a dummy javac and intercept options to check
* reception of options as passed through the launcher without having to launch
* reception of options as passed through the launcher without having to launch
...
...
编辑
预览
Markdown
is supported
0%
请重试
或
添加新附件
.
添加附件
取消
You are about to add
0
people
to the discussion. Proceed with caution.
先完成此消息的编辑!
取消
想要评论请
注册
或
登录