patch hook bounds to be inclusive

This commit is contained in:
Ryan Hileman 2016-01-22 19:24:45 -08:00
parent 2ac1281f82
commit 9f9bd7098b
1 changed files with 1 additions and 1 deletions

View File

@ -101,7 +101,7 @@ enum uc_hook_idx {
// if statement to check hook bounds
#define HOOK_BOUND_CHECK(hh, addr) \
((((addr) >= (hh)->begin && (addr) < (hh)->end) \
((((addr) >= (hh)->begin && (addr) <= (hh)->end) \
|| (hh)->begin > (hh)->end))
#define HOOK_EXISTS(uc, idx) ((uc)->hook[idx##_IDX].head != NULL)