diff -r f5907b1a1053 -r 0396474f30f5 emailuis/emailui/src/FreestyleEmailUiSendAttachmentsListModel.cpp --- a/emailuis/emailui/src/FreestyleEmailUiSendAttachmentsListModel.cpp Fri Mar 12 15:41:14 2010 +0200 +++ b/emailuis/emailui/src/FreestyleEmailUiSendAttachmentsListModel.cpp Mon Mar 15 12:39:10 2010 +0200 @@ -418,14 +418,15 @@ { FUNC_LOG; // empty the list - if ( iAttachmentsList ) + if ( !iAttachmentsList ) { - iAttachmentsList->RemoveAllL(); - iAttachmentsList->SetFocusedL(ETrue); + // Coverity error fix. iAttachmentsList was used also later without null checks + return; } - - iAttachmentsList->HideListL(); + iAttachmentsList->RemoveAllL(); + iAttachmentsList->SetFocusedL(ETrue); + iAttachmentsList->HideListL(); TRect screenRect; AknLayoutUtils::LayoutMetricsRect( AknLayoutUtils::EMainPane, screenRect ); iListLayout->SetSize( screenRect.Size() );