6783ab9f47
This updates OpenJDK 8 to a newer version and brings a bunch of changes. Newly, it is bootstrapped with openjdk7-bootstrap, so it does not need to download binaries. It can also cross-compile and is patched for musl and other platforms. We're newly using the aarch64 port repo in order to get aarch64 JIT. For non-aarch64 platforms, the codebase is the same. The symlink for /usr/lib/jvm/openjdk is also now gone and we're using a unified java-VERSION-VENDOR naming. Also general template cleanup. [ci skip]
42 lines
1.3 KiB
Diff
42 lines
1.3 KiB
Diff
--- openjdk/jdk/src/solaris/native/java/net/net_util_md.c.orig
|
|
+++ openjdk/jdk/src/solaris/native/java/net/net_util_md.c
|
|
@@ -561,7 +561,7 @@
|
|
|
|
static struct localinterface *localifs = 0;
|
|
static int localifsSize = 0; /* size of array */
|
|
-static int nifs = 0; /* number of entries used in array */
|
|
+static int nifs = -1; /* number of entries used in array */
|
|
|
|
/* not thread safe: make sure called once from one thread */
|
|
|
|
@@ -573,6 +573,10 @@
|
|
int index, x1, x2, x3;
|
|
unsigned int u0,u1,u2,u3,u4,u5,u6,u7,u8,u9,ua,ub,uc,ud,ue,uf;
|
|
|
|
+ if (nifs >= 0)
|
|
+ return ;
|
|
+ nifs = 0;
|
|
+
|
|
if ((f = fopen("/proc/net/if_inet6", "r")) == NULL) {
|
|
return ;
|
|
}
|
|
@@ -601,7 +605,7 @@
|
|
localifs = (struct localinterface *) realloc (
|
|
localifs, sizeof (struct localinterface)* (localifsSize+5));
|
|
if (localifs == 0) {
|
|
- nifs = 0;
|
|
+ nifs = -1;
|
|
fclose (f);
|
|
return;
|
|
}
|
|
@@ -624,9 +628,7 @@
|
|
static int getLocalScopeID (char *addr) {
|
|
struct localinterface *lif;
|
|
int i;
|
|
- if (localifs == 0) {
|
|
- initLocalIfs();
|
|
- }
|
|
+ initLocalIfs();
|
|
for (i=0, lif=localifs; i<nifs; i++, lif++) {
|
|
if (memcmp (addr, lif->localaddr, 16) == 0) {
|
|
return lif->index;
|