Skip to content
体验新版
项目
组织
正在加载...
登录
切换导航
打开侧边栏
openanolis
dragonwell11
提交
81a9787c
D
dragonwell11
项目概览
openanolis
/
dragonwell11
通知
7
Star
2
Fork
0
代码
文件
提交
分支
Tags
贡献者
分支图
Diff
Issue
0
列表
看板
标记
里程碑
合并请求
0
Wiki
0
Wiki
分析
仓库
DevOps
项目成员
Pages
D
dragonwell11
项目概览
项目概览
详情
发布
仓库
仓库
文件
提交
分支
标签
贡献者
分支图
比较
Issue
0
Issue
0
列表
看板
标记
里程碑
合并请求
0
合并请求
0
Pages
分析
分析
仓库分析
DevOps
Wiki
0
Wiki
成员
成员
收起侧边栏
关闭侧边栏
动态
分支图
创建新Issue
提交
Issue看板
体验新版 GitCode,发现更多精彩内容 >>
提交
81a9787c
编写于
7月 13, 2018
作者:
G
goetz
浏览文件
操作
浏览文件
下载
电子邮件补丁
差异文件
8207233: Minor improvements of jdk C-coding
Reviewed-by: rriggs, prr
上级
a1ded7af
变更
7
隐藏空白更改
内联
并排
Showing
7 changed file
with
20 addition
and
12 deletion
+20
-12
src/java.base/share/native/libzip/zip_util.c
src/java.base/share/native/libzip/zip_util.c
+2
-2
src/java.desktop/unix/native/common/awt/fontpath.c
src/java.desktop/unix/native/common/awt/fontpath.c
+2
-2
src/java.smartcardio/share/native/libj2pcsc/pcsc.c
src/java.smartcardio/share/native/libj2pcsc/pcsc.c
+4
-2
src/jdk.crypto.ec/share/native/libsunec/impl/ecl_mult.c
src/jdk.crypto.ec/share/native/libsunec/impl/ecl_mult.c
+2
-2
src/jdk.jdwp.agent/share/native/libjdwp/transport.c
src/jdk.jdwp.agent/share/native/libjdwp/transport.c
+2
-2
src/jdk.pack/share/native/common-unpack/unpack.cpp
src/jdk.pack/share/native/common-unpack/unpack.cpp
+4
-1
src/jdk.security.auth/unix/native/libjaas/Unix.c
src/jdk.security.auth/unix/native/libjaas/Unix.c
+4
-1
未找到文件。
src/java.base/share/native/libzip/zip_util.c
浏览文件 @
81a9787c
...
...
@@ -739,13 +739,13 @@ ZIP_Open_Generic(const char *name, char **pmsg, int mode, jlong lastModified)
jzfile
*
zip
=
NULL
;
/* Clear zip error message */
if
(
pmsg
!=
0
)
{
if
(
pmsg
!=
NULL
)
{
*
pmsg
=
NULL
;
}
zip
=
ZIP_Get_From_Cache
(
name
,
pmsg
,
lastModified
);
if
(
zip
==
NULL
&&
*
pmsg
==
NULL
)
{
if
(
zip
==
NULL
&&
pmsg
!=
NULL
&&
*
pmsg
==
NULL
)
{
ZFILE
zfd
=
ZFILE_Open
(
name
,
mode
);
zip
=
ZIP_Put_In_Cache
(
name
,
zfd
,
pmsg
,
lastModified
);
}
...
...
src/java.desktop/unix/native/common/awt/fontpath.c
浏览文件 @
81a9787c
/*
* Copyright (c) 1998, 201
6
, Oracle and/or its affiliates. All rights reserved.
* Copyright (c) 1998, 201
8
, Oracle and/or its affiliates. All rights reserved.
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
*
* This code is free software; you can redistribute it and/or modify it
...
...
@@ -265,7 +265,7 @@ static void AddFontsToX11FontPath ( fDirRecord *fDirP )
}
newFontPath
=
SAFE_SIZE_ARRAY_ALLOC
(
malloc
,
totalDirCount
,
sizeof
(
char
**
)
);
newFontPath
=
SAFE_SIZE_ARRAY_ALLOC
(
malloc
,
totalDirCount
,
sizeof
(
char
*
)
);
/* if it fails free things and get out */
if
(
newFontPath
==
NULL
)
{
free
(
(
void
*
)
appendDirList
);
...
...
src/java.smartcardio/share/native/libj2pcsc/pcsc.c
浏览文件 @
81a9787c
/*
* Copyright (c) 2005, 201
5
, Oracle and/or its affiliates. All rights reserved.
* Copyright (c) 2005, 201
8
, Oracle and/or its affiliates. All rights reserved.
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
*
* This code is free software; you can redistribute it and/or modify it
...
...
@@ -192,7 +192,7 @@ JNIEXPORT jobjectArray JNICALL Java_sun_security_smartcardio_PCSC_SCardListReade
}
dprintf1
(
"-size: %d
\n
"
,
size
);
if
(
size
)
{
if
(
size
!=
0
)
{
mszReaders
=
malloc
(
size
);
if
(
mszReaders
==
NULL
)
{
throwOutOfMemoryError
(
env
,
NULL
);
...
...
@@ -205,6 +205,8 @@ JNIEXPORT jobjectArray JNICALL Java_sun_security_smartcardio_PCSC_SCardListReade
return
NULL
;
}
dprintf1
(
"-String: %s
\n
"
,
mszReaders
);
}
else
{
return
NULL
;
}
result
=
pcsc_multi2jstring
(
env
,
mszReaders
);
...
...
src/jdk.crypto.ec/share/native/libsunec/impl/ecl_mult.c
浏览文件 @
81a9787c
/*
* Copyright (c) 2007, 201
7
, Oracle and/or its affiliates. All rights reserved.
* Copyright (c) 2007, 201
8
, Oracle and/or its affiliates. All rights reserved.
* Use is subject to license terms.
*
* This library is free software; you can redistribute it and/or
...
...
@@ -80,12 +80,12 @@ ECPoint_mul(const ECGroup *group, const mp_int *k, const mp_int *px,
group
,
timing
));
}
}
else
{
kt
.
flag
=
(
mp_sign
)
0
;
if
(
group
->
meth
->
field_enc
)
{
MP_CHECKOK
(
group
->
meth
->
field_enc
(
px
,
rx
,
group
->
meth
));
MP_CHECKOK
(
group
->
meth
->
field_enc
(
py
,
ry
,
group
->
meth
));
MP_CHECKOK
(
group
->
point_mul
(
&
kt
,
rx
,
ry
,
rx
,
ry
,
group
,
timing
));
}
else
{
kt
.
flag
=
(
mp_sign
)
0
;
MP_CHECKOK
(
group
->
point_mul
(
&
kt
,
px
,
py
,
rx
,
ry
,
group
,
timing
));
}
}
...
...
src/jdk.jdwp.agent/share/native/libjdwp/transport.c
浏览文件 @
81a9787c
/*
* Copyright (c) 1998, 201
7
, Oracle and/or its affiliates. All rights reserved.
* Copyright (c) 1998, 201
8
, Oracle and/or its affiliates. All rights reserved.
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
*
* This code is free software; you can redistribute it and/or modify it
...
...
@@ -211,7 +211,7 @@ loadTransport(const char *name, TransportInfo *info)
JNI_FUNC_PTR
(
env
,
GetJavaVM
)(
env
,
&
jvm
);
/* Try version 1.1 first, fallback to 1.0 on error */
for
(
i
=
0
;
i
<
sizeof
(
supported_versions
);
++
i
)
{
for
(
i
=
0
;
i
<
sizeof
(
supported_versions
)
/
sizeof
(
jint
)
;
++
i
)
{
rc
=
(
*
onLoad
)(
jvm
,
&
callback
,
supported_versions
[
i
],
&
t
);
if
(
rc
!=
JNI_EVERSION
)
{
info
->
transportVersion
=
supported_versions
[
i
];
...
...
src/jdk.pack/share/native/common-unpack/unpack.cpp
浏览文件 @
81a9787c
/*
* Copyright (c) 2001, 201
6
, Oracle and/or its affiliates. All rights reserved.
* Copyright (c) 2001, 201
8
, Oracle and/or its affiliates. All rights reserved.
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
*
* This code is free software; you can redistribute it and/or modify it
...
...
@@ -2681,6 +2681,9 @@ void unpacker::attr_definitions::readBandData(int idx) {
PRINTCR
((
1
,
"counted %d [redefined = %d predefined = %d] attributes of type %s.%s"
,
count
,
isRedefined
(
idx
),
isPredefined
(
idx
),
ATTR_CONTEXT_NAME
[
attrc
],
lo
->
name
));
}
else
{
abort
(
"layout_definition pointer must not be NULL"
);
return
;
}
bool
hasCallables
=
lo
->
hasCallables
();
band
**
bands
=
lo
->
bands
();
...
...
src/jdk.security.auth/unix/native/libjaas/Unix.c
浏览文件 @
81a9787c
/*
* Copyright (c) 2000, 201
6
, Oracle and/or its affiliates. All rights reserved.
* Copyright (c) 2000, 201
8
, Oracle and/or its affiliates. All rights reserved.
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
*
* This code is free software; you can redistribute it and/or modify it
...
...
@@ -64,6 +64,9 @@ Java_com_sun_security_auth_module_UnixSystem_getUnixInfo
jclass
cls
;
numSuppGroups
=
getgroups
(
0
,
NULL
);
if
(
numSuppGroups
==
-
1
)
{
return
;
}
groups
=
(
gid_t
*
)
calloc
(
numSuppGroups
,
sizeof
(
gid_t
));
if
(
groups
==
NULL
)
{
jclass
cls
=
(
*
env
)
->
FindClass
(
env
,
"java/lang/OutOfMemoryError"
);
...
...
编辑
预览
Markdown
is supported
0%
请重试
或
添加新附件
.
添加附件
取消
You are about to add
0
people
to the discussion. Proceed with caution.
先完成此消息的编辑!
取消
想要评论请
注册
或
登录