gpt4 book ai didi

android - Android 中的 StackOverflow 错误

转载 作者:塔克拉玛干 更新时间:2023-11-02 23:43:19 25 4
gpt4 key购买 nike

我在 Acer 平板电脑 上运行我的应用程序,应用程序每次都会崩溃,而应用程序在三星 平板电脑上运行完美。

02-13 09:48:05.400: D/OpenGLRenderer(7270): Flushing caches (mode 0)
02-13 09:48:07.700: D/dalvikvm(7270): GC_CONCURRENT freed 13419K, 65% free 7568K/21063K, paused 2ms+4ms
02-13 09:48:07.830: I/dalvikvm(7270): threadid=1: stack overflow on call to Landroid/widget/TextView;.onCreateDrawableState:LI
02-13 09:48:07.830: I/dalvikvm(7270): method requires 36+20+20=76 bytes, fp is 0x4001732c (44 left)
02-13 09:48:07.830: I/dalvikvm(7270): expanding stack end (0x40017300 to 0x40017000)
02-13 09:48:07.830: I/dalvikvm(7270): Shrank stack (to 0x40017300, curFrame is 0x40017500)
02-13 09:48:07.830: D/AndroidRuntime(7270): Shutting down VM
02-13 09:48:07.830: W/dalvikvm(7270): threadid=1: thread exiting with uncaught exception (group=0x40a561f8)
02-13 09:48:07.860: E/AndroidRuntime(7270): FATAL EXCEPTION: main
02-13 09:48:07.860: E/AndroidRuntime(7270): java.lang.StackOverflowError
02-13 09:48:07.860: E/AndroidRuntime(7270): at android.view.View.getDrawableState(View.java:11556)
02-13 09:48:07.860: E/AndroidRuntime(7270): at android.widget.TextView.onDraw(TextView.java:4863)
02-13 09:48:07.860: E/AndroidRuntime(7270): at android.view.View.draw(View.java:10983)
02-13 09:48:07.860: E/AndroidRuntime(7270): at android.view.View.getDisplayList(View.java:10422)
02-13 09:48:07.860: E/AndroidRuntime(7270): at android.view.ViewGroup.drawChild(ViewGroup.java:2850)
02-13 09:48:07.860: E/AndroidRuntime(7270): at android.view.ViewGroup.dispatchDraw(ViewGroup.java:2489)
02-13 09:48:07.860: E/AndroidRuntime(7270): at android.view.View.draw(View.java:10986)
02-13 09:48:07.860: E/AndroidRuntime(7270): at android.view.View.getDisplayList(View.java:10422)
02-13 09:48:07.860: E/AndroidRuntime(7270): at android.view.ViewGroup.drawChild(ViewGroup.java:2850)
02-13 09:48:07.860: E/AndroidRuntime(7270): at android.view.ViewGroup.dispatchDraw(ViewGroup.java:2489)
02-13 09:48:07.860: E/AndroidRuntime(7270): at android.view.View.getDisplayList(View.java:10420)
02-13 09:48:07.860: E/AndroidRuntime(7270): at android.view.ViewGroup.drawChild(ViewGroup.java:2850)
02-13 09:48:07.860: E/AndroidRuntime(7270): at android.view.ViewGroup.dispatchDraw(ViewGroup.java:2489)
02-13 09:48:07.860: E/AndroidRuntime(7270): at android.view.View.getDisplayList(View.java:10420)
02-13 09:48:07.860: E/AndroidRuntime(7270): at android.view.ViewGroup.drawChild(ViewGroup.java:2850)
02-13 09:48:07.860: E/AndroidRuntime(7270): at android.view.ViewGroup.dispatchDraw(ViewGroup.java:2489)
02-13 09:48:07.860: E/AndroidRuntime(7270): at android.view.View.getDisplayList(View.java:10420)
02-13 09:48:07.860: E/AndroidRuntime(7270): at android.view.ViewGroup.drawChild(ViewGroup.java:2850)
02-13 09:48:07.860: E/AndroidRuntime(7270): at android.view.ViewGroup.dispatchDraw(ViewGroup.java:2489)
02-13 09:48:07.860: E/AndroidRuntime(7270): at android.view.View.draw(View.java:10986)
02-13 09:48:07.860: E/AndroidRuntime(7270): at android.widget.FrameLayout.draw(FrameLayout.java:450)
02-13 09:48:07.860: E/AndroidRuntime(7270): at android.widget.ScrollView.draw(ScrollView.java:1524)
02-13 09:48:07.860: E/AndroidRuntime(7270): at android.view.View.getDisplayList(View.java:10422)
02-13 09:48:07.860: E/AndroidRuntime(7270): at android.view.ViewGroup.drawChild(ViewGroup.java:2850)
02-13 09:48:07.860: E/AndroidRuntime(7270): at android.view.ViewGroup.dispatchDraw(ViewGroup.java:2489)
02-13 09:48:07.860: E/AndroidRuntime(7270): at android.view.View.draw(View.java:10986)
02-13 09:48:07.860: E/AndroidRuntime(7270): at android.widget.FrameLayout.draw(FrameLayout.java:450)
02-13 09:48:07.860: E/AndroidRuntime(7270): at android.view.View.getDisplayList(View.java:10422)

请帮我解决这个问题

最佳答案

StackOverflowError正在运行的程序的堆栈深度超过某个平台或 VM 特定限制 时抛出。通常,这只会在程序变得无限递归时发生,但它也可能发生在正确编写(但深度递归)的程序中。

也许您的嵌套布局太多。

关于android - Android 中的 StackOverflow 错误,我们在Stack Overflow上找到一个类似的问题: https://stackoverflow.com/questions/21749387/

25 4 0
Copyright 2021 - 2024 cfsdn All Rights Reserved 蜀ICP备2022000587号
广告合作:1813099741@qq.com 6ren.com