提交 cc18989c 编写于 作者: C clanger

8165320: Small flaw when integrating 8160174 to JDK8

Reviewed-by: chegar, robm
上级 3d8c4fbc
......@@ -1350,9 +1350,9 @@ static int getFlags(int sock, const char *ifname, int *flags) {
static int openSocketWithFallback(JNIEnv *env, const char *ifname) {
int sock;
if ((sock = socket(AF_INET, SOCK_DGRAM, 0)) < 0) {
if ((sock = JVM_Socket(AF_INET, SOCK_DGRAM, 0)) < 0) {
if (errno == EPROTONOSUPPORT) {
if ((sock = socket(AF_INET6, SOCK_DGRAM, 0)) < 0) {
if ((sock = JVM_Socket(AF_INET6, SOCK_DGRAM, 0)) < 0) {
NET_ThrowByNameWithLastError
(env, JNU_JAVANETPKG "SocketException", "IPV6 Socket creation failed");
return -1;
......
Markdown is supported
0% .
You are about to add 0 people to the discussion. Proceed with caution.
先完成此消息的编辑!
想要评论请 注册