diff -r 7a522c0700d3 -r cce6680bbf1c persistentstorage/dbms/ustor/US_TABLE.CPP --- a/persistentstorage/dbms/ustor/US_TABLE.CPP Fri May 14 13:32:10 2010 +0100 +++ b/persistentstorage/dbms/ustor/US_TABLE.CPP Thu Jul 01 17:02:22 2010 +0100 @@ -611,7 +611,9 @@ TInt size; rec=ReadCardinality(rec,size); size<<=2; - if(size < 0) + + //If such huge allocation is requested(KMaxTInt/2), it is highly likely the file is corrupt + if((size < 0) || (size >= KMaxTInt/2)) { aRow.SetSize(0); __LEAVE(KErrCorrupt);