8230104: JNU_IsInstanceOfByName needs const parameter
authorrriggs
Fri, 23 Aug 2019 15:24:26 -0400
changeset 57868 7ae075afc72f
parent 57867 36f5e20be69a
child 57869 2d2c2428bf52
8230104: JNU_IsInstanceOfByName needs const parameter Reviewed-by: alanb, rriggs Contributed-by: andrewluotechnologies@outlook.com
src/java.base/share/native/libjava/jni_util.c
src/java.base/share/native/libjava/jni_util.h
--- a/src/java.base/share/native/libjava/jni_util.c	Fri Aug 23 19:55:08 2019 +0100
+++ b/src/java.base/share/native/libjava/jni_util.c	Fri Aug 23 15:24:26 2019 -0400
@@ -1096,7 +1096,7 @@
 }
 
 JNIEXPORT jint JNICALL
-JNU_IsInstanceOfByName(JNIEnv *env, jobject object, char* classname)
+JNU_IsInstanceOfByName(JNIEnv *env, jobject object, const char* classname)
 {
     jclass cls;
     if ((*env)->EnsureLocalCapacity(env, 1) < 0)
--- a/src/java.base/share/native/libjava/jni_util.h	Fri Aug 23 19:55:08 2019 +0100
+++ b/src/java.base/share/native/libjava/jni_util.h	Fri Aug 23 15:24:26 2019 -0400
@@ -208,7 +208,7 @@
  * has been thrown.
  */
 JNIEXPORT jint JNICALL
-JNU_IsInstanceOfByName(JNIEnv *env, jobject object, char *classname);
+JNU_IsInstanceOfByName(JNIEnv *env, jobject object, const char *classname);
 
 
 /* Get or set class and instance fields.