summaryrefslogtreecommitdiff
path: root/basic/source/comp/symtbl.cxx
diff options
context:
space:
mode:
Diffstat (limited to 'basic/source/comp/symtbl.cxx')
-rw-r--r--basic/source/comp/symtbl.cxx5
1 files changed, 3 insertions, 2 deletions
diff --git a/basic/source/comp/symtbl.cxx b/basic/source/comp/symtbl.cxx
index d6b3dbb878fc..9df91a5748b9 100644
--- a/basic/source/comp/symtbl.cxx
+++ b/basic/source/comp/symtbl.cxx
@@ -206,9 +206,10 @@ void SbiSymPool::Add( SbiSymDef* pDef )
SbiSymDef* SbiSymPool::Find( const String& rName ) const
{
- for( USHORT i = 0; i < aData.Count(); i++ )
+ USHORT nCount = aData.Count();
+ for( USHORT i = 0; i < nCount; i++ )
{
- SbiSymDef* p = aData.GetObject( i );
+ SbiSymDef* p = aData.GetObject( nCount - i - 1 );
if( ( !p->nProcId || ( p->nProcId == nProcId ) )
&& ( p->aName.EqualsIgnoreCaseAscii( rName ) ) )
return p;