使用Oreo(8.1)在开发人员控制台中本机崩溃中止 [英] Native crashes on abort in developer console with Oreo (8.1)
问题描述
在开发人员控制台中,我越来越多地中止本机崩溃.这仅适用于android 8.1设备! 有人知道回归吗?这是回溯:
In the developer console I get more and more a native crash in abort. This occurs ONLY for android 8.1 device! Is anybody aware of a regression? Here is the backtrace:
#00 pc 000000000001da4c /system/lib64/libc.so (abort+112)
#01 pc 0000000000007f7c /system/lib64/liblog.so (__android_log_assert+312)
#02 pc 000000000006cff8 /system/lib64/libhwui.so (android::uirenderer::renderthread::EglManager::createSurface(ANativeWindow*, bool)+324)
#03 pc 000000000006ad14 /system/lib64/libhwui.so (android::uirenderer::renderthread::OpenGLPipeline::setSurface(android::Surface*, android::uirenderer::renderthread::SwapBehavior, android::uirenderer::renderthread::ColorMode)+72)
#04 pc 00000000000679ec /system/lib64/libhwui.so (android::uirenderer::renderthread::CanvasContext::setSurface(android::Surface*)+144)
#05 pc 00000000000703bc /system/lib64/libhwui.so (android::uirenderer::renderthread::Bridge_initialize(android::uirenderer::renderthread::initializeArgs*)+16)
#06 pc 00000000000726c4 /system/lib64/libhwui.so (android::uirenderer::renderthread::MethodInvokeRenderTask::run()+24)
#07 pc 00000000000738d8 /system/lib64/libhwui.so (android::uirenderer::renderthread::RenderThread::threadLoop()+336)
#08 pc 0000000000011504 /system/lib64/libutils.so (android::Thread::_threadLoop(void*)+264)
#09 pc 00000000000a9830 /system/lib64/libandroid_runtime.so (android::AndroidRuntime::javaThreadShell(void*)+140)
#10 pc 0000000000069c94 /system/lib64/libc.so (__pthread_start(void*)+36)
#11 pc 000000000001eeec /system/lib64/libc.so (__start_thread+68)
更新:
我想这个问题只能由Google自己解决:(问题在这里 https://issuetracker.google进行跟踪. com/issues/70259031
同时,有人可以重现问题或至少解释问题发生的时间吗?这将有助于找到解决方法!
UPDATE:
I guess the issue can be solved only by Google themselves :( Issue is tracked here https://issuetracker.google.com/issues/70259031
In the meantime, could someone already reproduce the issue or at least explain when the issue occurs? This would help to find a workaround!
推荐答案
查看此答案:
tgkill-Android 8.0 Samsung S8上的本机错误
似乎它可能与Samsung S8和Samsung S8 +有关.
It seems it might be related to Samsung S8 and Samsung S8+.
基本上,如果对话框或对话框片段中有编辑文本,请突出显示该文本,然后关闭对话框(或更改方向),将发生此崩溃.
Basically, if you have an edit text in a dialog or dialog fragment, highlight the text and then close the dialog (or do an orientation change) this crash will occur.
要解决此问题,我必须在有问题的活动上关闭hardwareAcceleration-这可以在清单中完成,并且会导致活动滞后一些.
To resolve the issue, I had to turn off hardwareAcceleration on the offending activities - this can be done in the manifest and will cause the activity to lag a bit.
<activity android:name=".activities.CarDamageActivity"
android:hardwareAccelerated="false" />
为帮助防止在其他设备上出现延迟,可以检查设备型号,如果它不是S8或S8 +,请打开硬件加速.
To help prevent the lag on OTHER devices, one can check the device model and if it is NOT a S8 or S8+, turn ON the hardware acceleration.
String phoneMake = Build.MANUFACTURER;
String phoneModel = Build.MODEL.toUpperCase();
if (!(phoneMake.equalsIgnoreCase("samsung") && (phoneModel.startsWith("SM-G950")
|| phoneModel.startsWith("SM-G955")))) {
window.setFlags(
WindowManager.LayoutParams.FLAG_HARDWARE_ACCELERATED,
WindowManager.LayoutParams.FLAG_HARDWARE_ACCELERATED);
}
这篇关于使用Oreo(8.1)在开发人员控制台中本机崩溃中止的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!