加载私有库

时间:2015-09-30 02:28:09

标签: android linker dalvik native-code

SIGSEGV: SIGSEGV
#00 pc 4009a4c0 /system/bin/linker
#01 pc 4009b004 /system/bin/linker
#02 pc 4009b416 /system/bin/linker
#03 pc 4009b9ca /system/bin/linker
#04 pc 40099f42 /system/bin/linker
#05 pc 00051074 /system/lib/libdvm.so (_Z17dvmLoadNativeCodePKcP6ObjectPPc)
#06 pc 00068a18 /system/lib/libdvm.so
#07 pc 00027fa0 /system/lib/libdvm.so
#08 pc 0002f110 /system/lib/libdvm.so (_Z11dvmMterpStdP6Thread)
#09 pc 0002c774 /system/lib/libdvm.so (_Z12dvmInterpretP6ThreadPK6MethodP6JValue)
#10 pc 000619ea /system/lib/libdvm.so (_Z15dvmInvokeMethodP6ObjectPK6MethodP11ArrayObjectS5_P11ClassObjectb)
#11 pc 00069af6 /system/lib/libdvm.so
#12 pc 00027fa0 /system/lib/libdvm.so
#13 pc 0002f110 /system/lib/libdvm.so (_Z11dvmMterpStdP6Thread)
#14 pc 0002c774 /system/lib/libdvm.so (_Z12dvmInterpretP6ThreadPK6MethodP6JValue)
#15 pc 000619ea /system/lib/libdvm.so (_Z15dvmInvokeMethodP6ObjectPK6MethodP11ArrayObjectS5_P11ClassObjectb)
#16 pc 00069af6 /system/lib/libdvm.so
#17 pc 00027fa0 /system/lib/libdvm.so
#18 pc 0002f110 /system/lib/libdvm.so (_Z11dvmMterpStdP6Thread)
#19 pc 0002c774 /system/lib/libdvm.so (_Z12dvmInterpretP6ThreadPK6MethodP6JValue)
#20 pc 000619ea /system/lib/libdvm.so (_Z15dvmInvokeMethodP6ObjectPK6MethodP11ArrayObjectS5_P11ClassObjectb)
#21 pc 00069af6 /system/lib/libdvm.so
#22 pc 00027fa0 /system/lib/libdvm.so
#23 pc 0002f110 /system/lib/libdvm.so (_Z11dvmMterpStdP6Thread)
#24 pc 0002c774 /system/lib/libdvm.so (_Z12dvmInterpretP6ThreadPK6MethodP6JValue)
#25 pc 00061706 /system/lib/libdvm.so (_Z14dvmCallMethodVP6ThreadPK6MethodP6ObjectbP6JValueSt9__va_list)
#26 pc 0004ae1a /system/lib/libdvm.so
#27 pc 00050546 /system/lib/libandroid_runtime.so
#28 pc 000512d2 /system/lib/libandroid_runtime.so (_ZN7android14AndroidRuntime5startEPKcS2_)
#29 pc 4009605c /system/bin/app_process
#30 pc 0000e5e6 /system/lib/libc.so (__libc_init)
java:
java.lang.Runtime.nativeLoad(Native Method)
java.lang.Runtime.doLoad(Runtime.java:421)
java.lang.Runtime.load(Runtime.java:331)
java.lang.System.load(System.java:541)
.... 

在尝试加载私有库(.so)时,它在此行崩溃:

System.load(so_path);

此外,此代码是从自定义的 DexClassLoader 调用的,它会加载很多与“中的本机代码相关联的私有类。所以”

然而,在大多数设备上,它会定期加载。这个问题大多发现在android api等级为17,16,19的设备上。

是否有人对此问题有任何经验或想法?非常感谢你!

0 个答案:

没有答案