Read-only archive of the All About Symbian forum (2001–2013) · About this archive

please help me to recorrect this part program?thank you

0 replies · 808 views · Started 27 July 2005

when i run it in the program , it run normally
but when i shut down the program ,it display"program closed"
i detect the size of the stack, it increase when i run this part code.
if i get rid of this part , the size of stack is not increase
please help me , thank you!!!
this is the code :
TInt CContactIODocument::ImportL(RReadStream& aReadStream)
{
CContactDatabase* contactsDb = CContactDatabase::OpenL();
CleanupStack::PushL(contactsDb);

TBool result;
TUid p1;
p1.iUid = KVersitEntityUidVCard;
CArrayPtr<CContactItem>* imported = contactsDb->ImportContactsL(p1,
aReadStream,
result,
CContactDatabase::ETTFormat);
imported->ResetAndDestroy();
delete imported;

CleanupStack::PopAndDestroy(); // contactsDb

return result?KErrNone:KErrGeneral;


}