From: Marcus G. Daniels Date: Mon, 2 Apr 2001 22:52:40 +0000 (+0000) Subject: jni.cc (wrap_value): New specialization. X-Git-Url: https://git.libre-soc.org/?a=commitdiff_plain;h=56f2b5bd7666ba14cb5166d5a0b19da3906e5c69;p=gcc.git jni.cc (wrap_value): New specialization. 2001-04-02 Marcus G. Daniels * jni.cc (wrap_value): New specialization. From-SVN: r41021 --- diff --git a/libjava/ChangeLog b/libjava/ChangeLog index 2bc5aa82298..b371a4e6191 100644 --- a/libjava/ChangeLog +++ b/libjava/ChangeLog @@ -1,3 +1,7 @@ +2001-04-02 Marcus G. Daniels + + * jni.cc (wrap_value): New specialization. + 2001-04-02 Tom Tromey * java/io/PrintStream.java (out): Removed field. Fixes PR diff --git a/libjava/jni.cc b/libjava/jni.cc index b60823ee893..d41dd01e7bd 100644 --- a/libjava/jni.cc +++ b/libjava/jni.cc @@ -376,6 +376,15 @@ wrap_value (JNIEnv *env, jobject value) return value == NULL ? value : _Jv_JNI_NewLocalRef (env, value); } +template<> +static jclass +wrap_value (JNIEnv *env, jclass value) +{ + return (value == NULL + ? value + : (jclass) _Jv_JNI_NewLocalRef (env, (jobject) value)); +} + static jint