与Android 4.0或更高版本的应用程序崩溃

编程入门 行业动态 更新时间:2024-10-16 16:25:56
本文介绍了与Android 4.0或更高版本的应用程序崩溃的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧! 问题描述

我工作的一个应用程序,在那里我将采用Android NDK和放大器; JNI。 每当我在任何Android 4.0或更高版本上运行我的应用程序......我的应用程序将会崩溃,并给出了下面的错误...

I am working on a app, where I will use android NDK & JNI. Whenever I run my app on any android 4.0 or higher version... my app will crash and gives the following error...

A/libc(18556): Fatal signal 11 (SIGSEGV) at 0xdeadbaad (code=1) D/libEGL(18606): loaded /system/lib/egl/libGLES_android.so D/libEGL(18606): loaded /system/lib/egl/libEGL_adreno200.so D/libEGL(18606): loaded /system/lib/egl/libGLESv1_CM_adreno200.so D/libEGL(18606): loaded /system/lib/egl/libGLESv2_adreno200.so I/Adreno200-EGLSUB(18606): <ConfigWindowMatch:2078>: Format RGBA_8888. D/OpenGLRenderer(18606): Enabling debug mode 0

主要问题是在0xdeadbaad致命的信号11(SIGSEGV)(code = 1)

如果有谁知道这一点......然后告诉我的原因。

If anyone know about this... then tell me the reason.

推荐答案

首先,分割故障和,特别是0xdeadbaad,将意味着内存损坏或类似的,但是,我最近发现,与NDK,这也是断言默认行为:在断言失败发送,而不是SIGTRAP SIGSEGV,并将内存指针这个十六进制字符串

initially, the segmentation fault and, specially the 0xdeadbaad, would mean a memory corruption or similar but, I recently found that, with the NDK, this is also the default behaviour for assertions: on assert fail it sends SIGSEGV, instead of SIGTRAP, and sets the memory pointer to this hex string.

您应该检查你的code呼吁断言或者,如果你使用第三方的软件,请检查你传递正确的价值观,以每个呼叫。一个快速的方法来检查这将是构建库NDEBUG设置为1(默认情况下,如果你设置APP_OPTIM:=释放你的Application.mk),并检查您是否仍然有完全相同的问题

You should check that your code is calling to assert or, in case you're using third party's software, check that you're passing the proper values to every call. A quick way to check this would be building your library with NDEBUG set to 1 (by default if you set APP_OPTIM := release in your Application.mk) and check if you still have exactly the same problem.

希望这有助于。

更多推荐

与Android 4.0或更高版本的应用程序崩溃

本文发布于:2023-11-23 16:14:00,感谢您对本站的认可!
本文链接:https://www.elefans.com/category/jswz/34/1622088.html
版权声明:本站内容均来自互联网,仅供演示用,请勿用于商业和其他非法用途。如果侵犯了您的权益请与我们联系,我们将在24小时内删除。
本文标签:应用程序   或更高   版本   Android

发布评论

评论列表 (有 0 条评论)
草根站长

>www.elefans.com

编程频道|电子爱好者 - 技术资讯及电子产品介绍!