Why I am Getting Error 'Channel is unrecoverably broken and will be disposed!'
Have you used another UI thread? You shouldn't use more than 1 UI thread and make it look like a sandwich. Doing this will cause memory leaks.
I have solved a similar issue 2 days ago...
To keep things short: The main thread can have many UI threads to do multiple works, but if one sub-thread containing a UI thread is inside it, The UI thread may not have finished its work yet while it's parent thread has already finished its work, this causes memory leaks.
For example...for Fragment & UI application...this will cause memory leaks.
getActivity().runOnUiThread(new Runnable(){ public void run() {//No.1 ShowDataScreen();getActivity().runOnUiThread(new Runnable(){ public void run() {//No.2Toast.makeText(getActivity(), "This is error way",Toast.LENGTH_SHORT).show(); }});// end of No.2 UI new thread}});// end of No.1 UI new thread
My solution is rearrange as below:
getActivity().runOnUiThread(new Runnable(){ public void run() {//No.1ShowDataScreen();}});// end of No.1 UI new thread getActivity().runOnUiThread(new Runnable(){ public void run() {//No.2Toast.makeText(getActivity(), "This is correct way",Toast.LENGTH_SHORT).show();}});// end of No.2 UI new thread
for you reference.
I am Taiwanese, I am glad to answer here once more.