United StatesChange Country, Oracle Worldwide Web Sites Communities I am a... I want to...
Bug ID: JDK-8021899 Re-adjust fix of # 8020498 in 7u45 after mergeing 7u40
JDK-8021899 : Re-adjust fix of # 8020498 in 7u45 after mergeing 7u40

Details
Type:
Bug
Submit Date:
2013-07-30
Status:
Closed
Updated Date:
2013-10-16
Project Name:
JDK
Resolved Date:
2013-07-31
Component:
core-libs
OS:
generic
Sub-Component:
java.net
CPU:
generic
Priority:
P2
Resolution:
Fixed
Affected Versions:
7u45
Fixed Versions:
7u45 (b05)

Related Reports
Backport:
Backport:

Sub Tasks

Description
While syncing fixes from 7u40-b36 into 7u45-b05, we've seen that fix for #8020498 has been
causing build failure. We need to update the code and it is only applicable after the merge. 

8020498 renamed a function ( that was conflicting with another ), but 7u45 added some new callers of that function. We simply need to update the new callers.
                                    

Comments
$ hg diff src/share/native/java/net/net_util.c
diff --git a/src/share/native/java/net/net_util.c b/src/share/native/java/net/net_util.c
--- a/src/share/native/java/net/net_util.c
+++ b/src/share/native/java/net/net_util.c
@@ -1,5 +1,5 @@
 /*
- * Copyright (c) 1998, 2012, Oracle and/or its affiliates. All rights reserved.
+ * Copyright (c) 1998, 2013, 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
@@ -102,7 +102,7 @@ jobject getInet6Address_scopeifname(JNIE
 jobject getInet6Address_scopeifname(JNIEnv *env, jobject iaObj) {
     jobject holder;

-    init(env);
+    initInetAddrs(env);
     holder = (*env)->GetObjectField(env, iaObj, ia6_holder6ID);
     CHECK_NULL_RETURN(holder, NULL);
     return (*env)->GetObjectField(env, holder, ia6_scopeifnameID);
@@ -111,7 +111,7 @@ int setInet6Address_scopeifname(JNIEnv *
 int setInet6Address_scopeifname(JNIEnv *env, jobject iaObj, jobject scopeifname) {
     jobject holder;

-    init(env);
+    initInetAddrs(env);
     holder = (*env)->GetObjectField(env, iaObj, ia6_holder6ID);
     CHECK_NULL_RETURN(holder, JNI_FALSE);
     (*env)->SetObjectField(env, holder, ia6_scopeifnameID, scopeifname);
@@ -121,7 +121,7 @@ int getInet6Address_scopeifname_set(JNIE
 int getInet6Address_scopeifname_set(JNIEnv *env, jobject iaObj) {
     jobject holder;

-    init(env);
+    initInetAddrs(env);
     holder = (*env)->GetObjectField(env, iaObj, ia6_holder6ID);
     CHECK_NULL_RETURN(holder, -1);
     return (*env)->GetBooleanField(env, holder, ia6_scopeifnamesetID);
@@ -130,7 +130,7 @@ int setInet6Address_scopeifname_set(JNIE
 int setInet6Address_scopeifname_set(JNIEnv *env, jobject iaObj, int scopeifname_set) {
     jobject holder;

-    init(env);
+    initInetAddrs(env);
     holder = (*env)->GetObjectField(env, iaObj, ia6_holder6ID);
     CHECK_NULL_RETURN(holder, JNI_FALSE);
     (*env)->SetBooleanField(env, holder, ia6_scopeifnamesetID, scopeifname_set);
@@ -140,7 +140,7 @@ int getInet6Address_scopeid_set(JNIEnv *
 int getInet6Address_scopeid_set(JNIEnv *env, jobject iaObj) {
     jobject holder;

-    init(env);
+    initInetAddrs(env);
     holder = (*env)->GetObjectField(env, iaObj, ia6_holder6ID);
     CHECK_NULL_RETURN(holder, -1);
     return (*env)->GetBooleanField(env, holder, ia6_scopeidsetID);
@@ -149,7 +149,7 @@ int getInet6Address_scopeid(JNIEnv *env,
 int getInet6Address_scopeid(JNIEnv *env, jobject iaObj) {
     jobject holder;

-    init(env);
+    initInetAddrs(env);
     holder = (*env)->GetObjectField(env, iaObj, ia6_holder6ID);
     CHECK_NULL_RETURN(holder, -1);
     return (*env)->GetIntField(env, holder, ia6_scopeidID);
@@ -158,7 +158,7 @@ int setInet6Address_scopeid(JNIEnv *env,
 int setInet6Address_scopeid(JNIEnv *env, jobject iaObj, int scopeid) {
     jobject holder;

-    init(env);
+    initInetAddrs(env);
     holder = (*env)->GetObjectField(env, iaObj, ia6_holder6ID);
     CHECK_NULL_RETURN(holder, JNI_FALSE);
     (*env)->SetIntField(env, holder, ia6_scopeidID, scopeid);
@@ -173,7 +173,7 @@ int getInet6Address_ipaddress(JNIEnv *en
     jobject holder, addr;
     jbyteArray barr;

-    init(env);
+    initInetAddrs(env);
     holder = (*env)->GetObjectField(env, iaObj, ia6_holder6ID);
     CHECK_NULL_RETURN(holder, JNI_FALSE);
     addr =  (*env)->GetObjectField(env, holder, ia6_ipaddressID);
@@ -186,7 +186,7 @@ int setInet6Address_ipaddress(JNIEnv *en
     jobject holder;
     jbyteArray addr;

-    init(env);
+    initInetAddrs(env);
     holder = (*env)->GetObjectField(env, iaObj, ia6_holder6ID);
     CHECK_NULL_RETURN(holder, JNI_FALSE);
     addr =  (jbyteArray)(*env)->GetObjectField(env, holder, ia6_ipaddressID);


Chris Hegarty has reviewed this change. JPRT built successfully.
                                     
2013-07-30
8-na has been added to this bug. The above fix has effectively been applied to 8 during a merge.
                                     
2013-09-12



Hardware and Software, Engineered to Work Together