diff -r e686773b3f54 -r 04ab22b956c2 phonebookui/Phonebook2/CommandsExtension/src/CPbk2DeleteContactsCmd.cpp --- a/phonebookui/Phonebook2/CommandsExtension/src/CPbk2DeleteContactsCmd.cpp Tue Feb 02 10:12:17 2010 +0200 +++ b/phonebookui/Phonebook2/CommandsExtension/src/CPbk2DeleteContactsCmd.cpp Fri Feb 19 22:40:27 2010 +0200 @@ -276,6 +276,20 @@ } case EStarting: { + + // Returns NULL if there are no selected contacts. + // In that case we will delete the focused contact. + if ( iUiControl ) + { + //Re-Fetch the Contact Iterator + MPbk2ContactLinkIterator* contactIterator = iUiControl->SelectedContactsIteratorL(); + if ( contactIterator ) + { + delete iContactIterator; + iContactIterator = contactIterator; + } + } + if( iDecorator ) { iDecorator->ProcessStartedL( iContactCount );