diff -r 63c982fb92f2 -r b73252188534 harvester/server/src/reharvesterao.cpp --- a/harvester/server/src/reharvesterao.cpp Thu Jul 15 19:07:24 2010 +0300 +++ b/harvester/server/src/reharvesterao.cpp Thu Aug 19 10:20:41 2010 +0300 @@ -19,8 +19,8 @@ #include "mdeobject.h" #include "mdsutils.h" -const TInt KResumeTime = 2000000; //microseconds -const TInt KTimeIncrease = 500000; //microseconds +const TInt KResumeTime = 3000000; //microseconds +const TInt KTimeIncrease = 1000000; //microseconds const TInt KTimeLimit = 30000000; //microseconds // --------------------------------------------------------------------------- @@ -165,6 +165,7 @@ WRITELOG1("CReHarvesterAO::AddItem() - %S already exists in re-harvester queue", &aItem->Uri() ); #endif delete aItem; + aItem = NULL; return; } } @@ -173,11 +174,16 @@ if( mdeObject ) { delete mdeObject; + mdeObject = NULL; aItem->SetMdeObject( NULL ); } - iItems.Append( aItem ); - + if(iItems.Append( aItem ) != KErrNone ) + { + delete aItem; + aItem = NULL; + } + iDelay = KResumeTime; const TTimeIntervalMicroSeconds32 delay = TTimeIntervalMicroSeconds32( iDelay ); @@ -206,6 +212,7 @@ // found matching item iItems.Remove( i ); delete item; + item = NULL; } if ( iItems.Count() == 0 )