Hi expert,
This is about the Android JNI. My apps return a buffer from native to
java by jni NewDirectByteBuffer interface.
The Java method declared as:
public native ByteBuffer readData(int flags);
The JNI native method is as follows:
JNIEXPORT jobject JNICALL Java_com_lw_DataParser_readData
(JNIEnv *env, jobject obj, jint pageno)
{
...
jobject bb = (*env)->NewDirectByteBuffer(env, buffer, bsize);
return bb;
}
When I run it, it report below error:
12-16 23:49:54.307: WARN/dalvikvm(653): JNI WARNING: method declared
to return 'Ljava/nio/ByteBuffer;' returned 'Ljava/nio/
ReadWriteDirectByteBuffer;'
12-16 23:49:54.307: WARN/dalvikvm(653): failed in Lcom/lw/
mupdf/PdfViewer;.readPage ('Ljava/nio/ByteBuffer;' not found)
What's the meaning of "failed in Lcom/lw/mupdf/PdfViewer;.readPage
('Ljava/nio/ByteBuffer;' not found)? And how to solve it?
-Thanks
--
You received this message because you are subscribed to the Google
Groups "Android Developers" group.
To post to this group, send email to [email protected]
To unsubscribe from this group, send email to
[email protected]
For more options, visit this group at
http://groups.google.com/group/android-developers?hl=en