1
0
mirror of https://github.com/danog/libtgvoip.git synced 2025-01-22 13:01:21 +01:00

crash fix

This commit is contained in:
Grishka 2018-02-03 20:21:58 +04:00
parent 6b0d4a6cc3
commit e7e7d2f05e

View File

@ -177,13 +177,12 @@ extern "C" JNIEXPORT void Java_org_telegram_messenger_voip_VoIPController_native
}
extern "C" JNIEXPORT void Java_org_telegram_messenger_voip_VoIPController_nativeRelease(JNIEnv* env, jobject thiz, jlong inst){
//env->DeleteGlobalRef(AudioInputAndroid::jniClass);
VoIPController* ctlr=((VoIPController*)(intptr_t)inst);
impl_data_android_t* impl=(impl_data_android_t*)ctlr->implData;
env->DeleteGlobalRef(impl->javaObject);
jobject jobj=impl->javaObject;
free(impl);
delete ctlr;
env->DeleteGlobalRef(jobj);
}