diff options
author | Pierre-André Jacquod <pjacquod@alumni.ethz.ch> | 2011-10-03 17:24:43 +0200 |
---|---|---|
committer | Pierre-André Jacquod <pjacquod@alumni.ethz.ch> | 2011-10-07 15:57:56 +0200 |
commit | 90645b9be8976681a2110ce40f7fb4f54b30edfa (patch) | |
tree | 7d9609ed84c0be5b802b9d8c6774ae7019512d51 /soltools | |
parent | d97b1a730547c6b40b07e20e6eccf3440b4b30b2 (diff) |
do not check if unsigned is less than zero in in soltools/..hastbl.cxx
Diffstat (limited to 'soltools')
-rw-r--r-- | soltools/ldump/hashtbl.cxx | 11 |
1 files changed, 6 insertions, 5 deletions
diff --git a/soltools/ldump/hashtbl.cxx b/soltools/ldump/hashtbl.cxx index 712357f3a7fe..ed17911c3992 100644 --- a/soltools/ldump/hashtbl.cxx +++ b/soltools/ldump/hashtbl.cxx @@ -405,11 +405,12 @@ void* HashTableIterator::GetNext() void* HashTableIterator::GetPrev() { - if (m_lAt <= 0) - return NULL; - - m_lAt--; - return FindValidObject(false /* backward */); + if (m_lAt) + { + --m_lAt; + return FindValidObject(false /* backward */); + } + return NULL; } void* HashTableIterator::FindValidObject(bool bForward) |