const reference in HashTableT<>::getOccupiedSlotNum()

Flagged by Flexelint
This commit is contained in:
Ivan Skytte Jørgensen
2016-03-14 22:36:33 +01:00
parent cea0793984
commit 9ab1bbb21a
2 changed files with 2 additions and 2 deletions

@ -115,7 +115,7 @@ void HashTableT<Key_t, Val_t>::clear ( ) {
// . returns the slot number for "key"
// . returns -1 if key not in hash table
template<class Key_t, class Val_t>
int32_t HashTableT<Key_t, Val_t>::getOccupiedSlotNum ( Key_t& key ) const {
int32_t HashTableT<Key_t, Val_t>::getOccupiedSlotNum ( const Key_t& key ) const {
if ( m_numSlots <= 0 ) return -1;
int64_t n;
/*

@ -81,7 +81,7 @@ class HashTableT {
bool setTableSize ( int32_t numSlots, char *buf, int32_t bufSize );
int32_t getOccupiedSlotNum ( Key_t& key ) const;
int32_t getOccupiedSlotNum ( const Key_t& key ) const;
//private:
//friend class RequestTable;