开发者

My app just crashed, how can I get the crash log?

开发者 https://www.devze.com 2023-01-15 00:46 出处:网络
I am testing my app on my actual device, and it seems like there is a memory leak. The app has crashed after a couple of hours. How can I pull up the log of the crash?

I am testing my app on my actual device, and it seems like there is a memory leak. The app has crashed after a couple of hours. How can I pull up the log of the crash?

I plugged my phone in via USB and tried:

adb logcat -v

but I get the following message in my terminal:

开发者_运维技巧- waiting for device -
error: more than one device and emulator

How can I diagnose my crash?


That's because there's...

more than one device and emulator

The error is fairly clear. So, what you do in this case is:

adb devices

And it lists the name of your devices/emulators. Then:

adb -s name-of-your-device logcat 
0

精彩评论

暂无评论...
验证码 换一张
取 消