hadoop-lzo icon indicating copy to clipboard operation
hadoop-lzo copied to clipboard

JNI issue in LzoDecompressor_decompressBytesDirect

Open luchsh opened this issue 7 years ago • 0 comments

The type of the second parameter of GetStaticObjectField should be 'jclass' instead of 'jobject', this can be found by specifying jvm option "-Xcheck:jni".

JNIEXPORT jint JNICALL
Java_com_hadoop_compression_lzo_LzoDecompressor_decompressBytesDirect(
	JNIEnv *env, jobject this, jint decompressor
	) {
.....
	// Get members of LzoDecompressor
	clazz = (*env)->GetStaticObjectField(env, this, 
	                                             LzoDecompressor_clazz);

luchsh avatar Dec 18 '17 07:12 luchsh