gpt4 book ai didi

java - 我的应用程序刚刚崩溃,如何获取崩溃日志?

转载 作者:太空狗 更新时间:2023-10-29 15:49:32 25 4
gpt4 key购买 nike

我正在我的实际设备上测试我的应用程序,似乎存在内存泄漏。该应用程序在几个小时后崩溃了。如何提取崩溃日志?

我通过 USB 插入手机并尝试:

adb logcat -v

但我在终端中收到以下消息:

- waiting for device -
error: more than one device and emulator

如何诊断我的崩溃?

最佳答案

那是因为有...

more than one device and emulator

错误很明显。因此,在这种情况下您要做的是:

adb devices

它列出了您的设备/模拟器的名称。然后:

adb -s name-of-your-device logcat 

关于java - 我的应用程序刚刚崩溃,如何获取崩溃日志?,我们在Stack Overflow上找到一个类似的问题: https://stackoverflow.com/questions/3664630/

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