aboutsummaryrefslogtreecommitdiff
path: root/src/hashtable.cpp
diff options
context:
space:
mode:
Diffstat (limited to 'src/hashtable.cpp')
-rw-r--r--src/hashtable.cpp8
1 files changed, 4 insertions, 4 deletions
diff --git a/src/hashtable.cpp b/src/hashtable.cpp
index 725ebc4..dbcd964 100644
--- a/src/hashtable.cpp
+++ b/src/hashtable.cpp
@@ -41,7 +41,7 @@ bool HashTable::isFilled( int j )
41 return (aTable[j].id != NULL)||(aTable[j].bDeleted); 41 return (aTable[j].id != NULL)||(aTable[j].bDeleted);
42} 42}
43 43
44bool HashTable::reHash( unsigned long int nNewSize ) 44void HashTable::reHash( unsigned long int nNewSize )
45{ 45{
46 HashNode *aOldTable = aTable; 46 HashNode *aOldTable = aTable;
47 unsigned long int oldSize = nTableSize; 47 unsigned long int oldSize = nTableSize;
@@ -90,7 +90,7 @@ unsigned long int HashTable::probe( unsigned long int nStart, const void *id )
90 */ 90 */
91 if( isFilled( nStart ) ) 91 if( isFilled( nStart ) )
92 { 92 {
93 int nOldStart = nStart; 93 unsigned long int nOldStart = nStart;
94 for( 94 for(
95 nStart++; 95 nStart++;
96 isFilled( nStart ) && nStart != nOldStart; 96 isFilled( nStart ) && nStart != nOldStart;
@@ -221,7 +221,7 @@ const void *HashTable::get( const void *id, unsigned long int nSkip )
221 221
222 if( bAllowDupes ) 222 if( bAllowDupes )
223 { 223 {
224 int nOldPos = nPos; 224 unsigned long int nOldPos = nPos;
225 for( nPos++; nPos != nOldPos; nPos=(nPos+1)%nTableSize ) 225 for( nPos++; nPos != nOldPos; nPos=(nPos+1)%nTableSize )
226 { 226 {
227 if( !isFilled( nPos ) ) return NULL; 227 if( !isFilled( nPos ) ) return NULL;
@@ -270,7 +270,7 @@ const void *HashTable::getKey( const void *id, unsigned long int nSkip )
270 270
271 if( bAllowDupes ) 271 if( bAllowDupes )
272 { 272 {
273 int nOldPos = nPos; 273 unsigned long int nOldPos = nPos;
274 for( nPos++; nPos != nOldPos; nPos=(nPos+1)%nTableSize ) 274 for( nPos++; nPos != nOldPos; nPos=(nPos+1)%nTableSize )
275 { 275 {
276 if( !isFilled( nPos ) ) return NULL; 276 if( !isFilled( nPos ) ) return NULL;