From a35b58fd61e023096c7d073819067ffcda219358 Mon Sep 17 00:00:00 2001 From: gir489 Date: Fri, 15 Jun 2018 08:18:01 -0500 Subject: [PATCH] Removed extraneous dwAddress initializer. --- SigMaker/Search.cpp | 25 +++++++++++-------------- 1 file changed, 11 insertions(+), 14 deletions(-) diff --git a/SigMaker/Search.cpp b/SigMaker/Search.cpp index e58325f..3fbad0a 100644 --- a/SigMaker/Search.cpp +++ b/SigMaker/Search.cpp @@ -12,20 +12,17 @@ bool HasOneHitSig( qSigVector& vecSig ) int GetOccurenceCount( const qstring& strSig, bool bSkipOut = false ) { int iCount = 0; - ea_t dwAddress = find_binary( inf.min_ea, inf.max_ea, strSig.c_str( ), 16, SEARCH_DOWN ); - - dwAddress = find_binary(inf.omin_ea, inf.omax_ea, strSig.c_str(), 16, SEARCH_DOWN); - if (IsValidEA(dwAddress)) + ea_t dwAddress = find_binary(inf.omin_ea, inf.omax_ea, strSig.c_str(), 16, SEARCH_DOWN); + if (IsValidEA(dwAddress)) + { + do { - do - { - if (bSkipOut == true && iCount >= 2) - return iCount; - iCount++; - dwAddress = find_binary(dwAddress + 1, inf.omax_ea, strSig.c_str(), 16, SEARCH_DOWN); - } while (IsValidEA(dwAddress)); - } - + if (bSkipOut == true && iCount >= 2) + return iCount; + iCount++; + dwAddress = find_binary(dwAddress + 1, inf.omax_ea, strSig.c_str(), 16, SEARCH_DOWN); + } while (IsValidEA(dwAddress)); + } return iCount; } @@ -175,4 +172,4 @@ void ShowSearchWindow( void ) SearchForSigs( strSig ); hide_wait_box( ); } -} \ No newline at end of file +}