From 7dfe7e55a01dd3dc26825b9779f7d5abb94e33db Mon Sep 17 00:00:00 2001 From: bpittore Date: Fri, 15 Mar 2013 15:20:40 -0400 Subject: [PATCH] 8005716: Enhance JNI specification to allow support of static JNI libraries in Embedded JREs Reviewed-by: dlong, alanb, mduigou --- src/share/vm/prims/jni.cpp | 4 ++-- src/share/vm/prims/jni.h | 3 ++- src/share/vm/runtime/thread.cpp | 1 + 3 files changed, 5 insertions(+), 3 deletions(-) diff --git a/src/share/vm/prims/jni.cpp b/src/share/vm/prims/jni.cpp index f45568a7c..22716c400 100644 --- a/src/share/vm/prims/jni.cpp +++ b/src/share/vm/prims/jni.cpp @@ -1,5 +1,5 @@ /* - * Copyright (c) 1997, 2012, Oracle and/or its affiliates. All rights reserved. + * Copyright (c) 1997, 2013, Oracle and/or its affiliates. All rights reserved. * Copyright (c) 2012 Red Hat, Inc. * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. * @@ -92,7 +92,7 @@ # include "os_bsd.inline.hpp" #endif -static jint CurrentVersion = JNI_VERSION_1_6; +static jint CurrentVersion = JNI_VERSION_1_8; // The DT_RETURN_MARK macros create a scoped object to fire the dtrace diff --git a/src/share/vm/prims/jni.h b/src/share/vm/prims/jni.h index a67c2e540..582f2c970 100644 --- a/src/share/vm/prims/jni.h +++ b/src/share/vm/prims/jni.h @@ -1,5 +1,5 @@ /* - * Copyright (c) 1997, 2010, Oracle and/or its affiliates. All rights reserved. + * Copyright (c) 1997, 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 @@ -1951,6 +1951,7 @@ JNI_OnUnload(JavaVM *vm, void *reserved); #define JNI_VERSION_1_2 0x00010002 #define JNI_VERSION_1_4 0x00010004 #define JNI_VERSION_1_6 0x00010006 +#define JNI_VERSION_1_8 0x00010008 #ifdef __cplusplus } /* extern "C" */ diff --git a/src/share/vm/runtime/thread.cpp b/src/share/vm/runtime/thread.cpp index cb883c5d8..322597fe4 100644 --- a/src/share/vm/runtime/thread.cpp +++ b/src/share/vm/runtime/thread.cpp @@ -4061,6 +4061,7 @@ jboolean Threads::is_supported_jni_version(jint version) { if (version == JNI_VERSION_1_2) return JNI_TRUE; if (version == JNI_VERSION_1_4) return JNI_TRUE; if (version == JNI_VERSION_1_6) return JNI_TRUE; + if (version == JNI_VERSION_1_8) return JNI_TRUE; return JNI_FALSE; } -- GitLab