帖子

语音唤醒和语音听写的报错

[复制链接]

该用户从未签到

46122  楼主| qiweimin 发表于 2018-12-28 16:55:52 1#
在进行讯飞语音听写和语音开发中,遇到程序报这样的错误:

12-28 15:37:32.550 4704-6852/com.example.irobot.activity E/art: JNI ERROR (app bug): accessed deleted Global 0x100992
12-28 15:37:32.581 4704-6854/com.example.irobot.activity D/MscSpeechLog: onVolumeChanged
12-28 15:37:32.600 4704-6852/com.example.irobot.activity A/art: art/runtime/java_vm_ext.cc:470] JNI DETECTED ERROR IN APPLICATION: use of deleted global reference 0x100992
    art/runtime/java_vm_ext.cc:470]     from int com.iflytek.msc.MSC.QIVWAudioWrite(char[], byte[], int, int, com.iflytek.msc.MSCSessionInfo)
    art/runtime/java_vm_ext.cc:470] "wakeuper" prio=5 tid=48 Runnable
12-28 15:37:32.601 4704-6852/com.example.irobot.activity A/art: art/runtime/java_vm_ext.cc:470]   | group="main" sCount=0 dsCount=0 obj=0x12cb53a0 self=0xa1644b00
    art/runtime/java_vm_ext.cc:470]   | sysTid=6852 nice=0 cgrp=default sched=0/0 handle=0x952ff920
    art/runtime/java_vm_ext.cc:470]   | state=R schedstat=( 3061138185 2709194585 3064 ) utm=295 stm=10 core=3 HZ=100
    art/runtime/java_vm_ext.cc:470]   | stack=0x951fd000-0x951ff000 stackSize=1038KB
    art/runtime/java_vm_ext.cc:470]   | held mutexes= "mutator lock"(shared held)
    art/runtime/java_vm_ext.cc:470]   native: #00 pc 00350ab5  /system/lib/libart.so (_ZN3art15DumpNativeStackERNSt3__113basic_ostreamIcNS0_11char_traitsIcEEEEiP12BacktraceMapPKcPNS_9ArtMethodEPv+128)
    art/runtime/java_vm_ext.cc:470]   native: #01 pc 003311f9  /system/lib/libart.so (_ZNK3art6Thread9DumpStackERNSt3__113basic_ostreamIcNS1_11char_traitsIcEEEEbP12BacktraceMap+308)
    art/runtime/java_vm_ext.cc:470]   native: #02 pc 00239895  /system/lib/libart.so (_ZN3art9JavaVMExt8JniAbortEPKcS2_+848)
    art/runtime/java_vm_ext.cc:470]   native: #03 pc 00239e2b  /system/lib/libart.so (_ZN3art9JavaVMExt9JniAbortFEPKcS2_z+66)
    art/runtime/java_vm_ext.cc:470]   native: #04 pc 00334c25  /system/lib/libart.so (_ZNK3art6Thread13DecodeJObjectEP8_jobject+240)
    art/runtime/java_vm_ext.cc:470]   native: #05 pc 000ca321  /system/lib/libart.so (_ZN3art11ScopedCheck13CheckInstanceERNS_18ScopedObjectAccessENS0_12InstanceKindEP8_jobjectb+120)
    art/runtime/java_vm_ext.cc:470]   native: #06 pc 000c98d3  /system/lib/libart.so (_ZN3art11ScopedCheck22CheckPossibleHeapValueERNS_18ScopedObjectAccessEcNS_12JniValueTypeE+190)
    art/runtime/java_vm_ext.cc:470]   native: #07 pc 000c8d0b  /system/lib/libart.so (_ZN3art11ScopedCheck5CheckERNS_18ScopedObjectAccessEbPKcPNS_12JniValueTypeE+802)
    art/runtime/java_vm_ext.cc:470]   native: #08 pc 000cceb7  /system/lib/libart.so (_ZN3art8CheckJNI13CheckCallArgsERNS_18ScopedObjectAccessERNS_11ScopedCheckEP7_JNIEnvP8_jobjectP7_jclassP10_jmethodIDNS_10InvokeTypeEPKNS_7VarArgsE+114)
    art/runtime/java_vm_ext.cc:470]   native: #09 pc 000cc4e5  /system/lib/libart.so (_ZN3art8CheckJNI11CallMethodVEPKcP7_JNIEnvP8_jobjectP7_jclassP10_jmethodIDSt9__va_listNS_9Primitive4TypeENS_10InvokeTypeE+512)
    art/runtime/java_vm_ext.cc:470]   native: #10 pc 000c2275  /system/lib/libart.so (_ZN3art8CheckJNI14CallIntMethodVEP7_JNIEnvP8_jobjectP10_jmethodIDSt9__va_list+44)
    art/runtime/java_vm_ext.cc:470]   native: #11 pc 00168ee4  /data/app/com.example.irobot.activity-1/lib/arm/libmsc.so (_ZN7_JNIEnv13CallIntMethodEP8_jobjectP10_jmethodIDz+36)
    art/runtime/java_vm_ext.cc:470]   native: #12 pc 00169438  /data/app/com.example.irobot.activity-1/lib/arm/libmsc.so (_Z16JNI_IvwMsgProcCBPKciiiPKvPv+204)
    art/runtime/java_vm_ext.cc:470]   native: #13 pc 001295c0  /data/app/com.example.irobot.activity-1/lib/arm/libmsc.so (???)
    art/runtime/java_vm_ext.cc:470]   native: #14 pc 00165c6c  /data/app/com.example.irobot.activity-1/lib/arm/libmsc.so (IvwWakeupCallBack+1516)
    art/runtime/java_vm_ext.cc:470]   native: #15 pc 00183d38  /data/app/com.example.irobot.activity-1/lib/arm/libmsc.so (_ZN7IvwInst13dec_one_frameEiPKs+340)
    art/runtime/java_vm_ext.cc:470]   native: #16 pc 00183f48  /data/app/com.example.irobot.activity-1/lib/arm/libmsc.so (_ZN7IvwInst14wIvwWriteNoVadEPci+104)
    art/runtime/java_vm_ext.cc:470]   native: #17 pc 001850f4  /data/app/com.example.irobot.activity-1/lib/arm/libmsc.so (_ZN7IvwInst9wIvwWriteEPKcii+668)
    art/runtime/java_vm_ext.cc:470]   native: #18 pc 00172370  /data/app/com.example.irobot.activity-1/lib/arm/libmsc.so (_ZN13IVWEngineFace35IVWF8F4A1B3FE7C471DB32BE1F2CFF09E77EPvPci+60)
    art/runtime/java_vm_ext.cc:470]   native: #19 pc 00172155  /data/app/com.example.irobot.activity-1/lib/arm/libmsc.so (wIvw_AudioWriteInst+10)
    art/runtime/java_vm_ext.cc:470]   native: #20 pc 00166e0c  /data/app/com.example.irobot.activity-1/lib/arm/libmsc.so (Ivw_AppendDataSyn+776)
    art/runtime/java_vm_ext.cc:470]   native: #21 pc 0012ade8  /data/app/com.example.irobot.activity-1/lib/arm/libmsc.so (QIVWAudioWrite+584)
    art/runtime/java_vm_ext.cc:470]   native: #22 pc 0016d410  /data/app/com.example.irobot.activity-1/lib/arm/libmsc.so (Java_com_iflytek_msc_MSC_QIVWAudioWrite+80)
    art/runtime/java_vm_ext.cc:470]   native: #23 pc 000ae399  /system/lib/libart.so (art_quick_generic_jni_trampoline+40)
    art/runtime/java_vm_ext.cc:470]   native: #24 pc 0002987f  /dev/ashmem/dalvik-jit-code-cache (deleted) (???)
    art/runtime/java_vm_ext.cc:470]   at com.iflytek.msc.MSC.QIVWAudioWrite(Native method)
    art/runtime/java_vm_ext.cc:470]   at com.iflytek.cloud.thirdparty.j.a(SourceFile:81)
    art/runtime/java_vm_ext.cc:470]   - locked <0x0895da4a> (a com.iflytek.cloud.thirdparty.j)
    art/runtime/java_vm_ext.cc:470]   at com.iflytek.cloud.thirdparty.j.a(SourceFile:76)
    art/runtime/java_vm_ext.cc:470]   - locked <0x0895da4a> (a com.iflytek.cloud.thirdparty.j)
    art/runtime/java_vm_ext.cc:470]   at com.iflytek.cloud.thirdparty.k.a(SourceFile:693)
    art/runtime/java_vm_ext.cc:470]   at com.iflytek.cloud.thirdparty.k.a(SourceFile:253)
    art/runtime/java_vm_ext.cc:470]   at com.iflytek.cloud.thirdparty.k.onMsgProcess(SourceFile:149)
    art/runtime/java_vm_ext.cc:470]   at com.iflytek.cloud.thirdparty.s.handleMessage(SourceFile:201)
    art/runtime/java_vm_ext.cc:470]   at android.os.Handler.dispatchMessage(Handler.java:102)
    art/runtime/java_vm_ext.cc:470]   at android.os.Looper.loop(Looper.java:154)
    art/runtime/java_vm_ext.cc:470]   at android.os.HandlerThread.run(HandlerThread.java:61)
    art/runtime/java_vm_ext.cc:470]


请问各位大侠,一般这是什么原因造成?
讯飞2017hj 发表于 2018-12-29 14:04:55
2#
这个看不出来,具体的错误码是多少呢,或者使用sdk中的demo测试一下是否正常呢。
使用道具 举报 回复
 楼主| qiweimin 发表于 2019-1-5 12:18:16
3#
没有错误码,只有退出码:
12-24 15:55:38.739 3032-3640/com.example.irobot.activity A/libc: Fatal signal 6 (SIGABRT), code -6 in tid 3640 (wakeuper)

这是JNI报的错。我的程序是一直运行,唤醒处于准备状态。这个错并不是即时出的,而是运行相当一段时间30分钟甚至几小时之后才出。
例子demo没有报这个错,但由于demo不会运行那么长时间,所以没有出现过这个错。
使用道具 举报 回复