RegisterNatives() returns 0 on success.
cf. http://docs.oracle.com/javase/6/docs/technotes/guides/jni/spec/functions.html#wp5833 Change-Id: I2c599f2d8765a7475c7076e6b049f77ad79feb79main
parent
317075e00d
commit
63b48311b0
|
@ -67,7 +67,7 @@ int registerNativeMethods(JNIEnv *env, const char *const className, const JNINat
|
||||||
AKLOGE("Native registration unable to find class '%s'", className);
|
AKLOGE("Native registration unable to find class '%s'", className);
|
||||||
return JNI_FALSE;
|
return JNI_FALSE;
|
||||||
}
|
}
|
||||||
if (env->RegisterNatives(clazz, methods, numMethods) < 0) {
|
if (env->RegisterNatives(clazz, methods, numMethods) != 0) {
|
||||||
AKLOGE("RegisterNatives failed for '%s'", className);
|
AKLOGE("RegisterNatives failed for '%s'", className);
|
||||||
env->DeleteLocalRef(clazz);
|
env->DeleteLocalRef(clazz);
|
||||||
return JNI_FALSE;
|
return JNI_FALSE;
|
||||||
|
|
Loading…
Reference in New Issue