mirror of
https://github.com/moparisthebest/Yaaic
synced 2024-11-26 02:42:16 -05:00
MessageListAdapter: Synchonize the addMessage() method as the LinkedList may throw an ConcurrentModificationException
This commit is contained in:
parent
3a3e4ae822
commit
35f430ad9b
@ -73,7 +73,7 @@ public class MessageListAdapter extends BaseAdapter
|
|||||||
*
|
*
|
||||||
* @param message
|
* @param message
|
||||||
*/
|
*/
|
||||||
public void addMessage(Message message)
|
public synchronized void addMessage(Message message)
|
||||||
{
|
{
|
||||||
messages.add(message.renderTextView(context));
|
messages.add(message.renderTextView(context));
|
||||||
notifyDataSetChanged();
|
notifyDataSetChanged();
|
||||||
|
Loading…
Reference in New Issue
Block a user