adb logcat: Increase the maximal message length

后端 未结 2 1565
小鲜肉
小鲜肉 2021-01-19 19:16

it seems like logcat truncates very long log messages, is there a way to prevent this?

$ adb logcat -g
ring buffer is 64Kb (63Kb consumed), max entry is 2048         


        
2条回答
  •  走了就别回头了
    2021-01-19 20:00

    Maybe you can create a custom class, which to you send your logmessages, which then divides them into multiple messages. like:

    MyLogger.d("LOG_TAG",veryLongMessage);  
    

    This class then just could check the size of the message, and split it up if nessecary, and then pass them into Log.d().

提交回复
热议问题