Added a null pointer check to protect from NullPointerExceptions.

See issue 1749
This commit is contained in:
cketti 2010-06-21 18:17:10 +00:00
parent 25f5469497
commit 7adc168471
1 changed files with 10 additions and 1 deletions

View File

@ -1926,7 +1926,16 @@ public class MessageList
{
for (MessageInfoHolder holder : mAdapter.messages)
{
if (holder.message.equalsReference(messageReference))
/*
* 2010-06-21 - cketti
* Added null pointer check. Not sure what's causing 'holder'
* to be null. See log provided in issue 1749, comment #15.
*
* Please remove this comment once the cause was found and the
* bug(?) fixed.
*/
if ((holder != null) &&
holder.message.equalsReference(messageReference))
{
return holder;
}