checkstack: Handle callw instruction

Minor update to the checkstack.py tool.

Signed-off-by: Kevin O'Connor <kevin@koconnor.net>
This commit is contained in:
Kevin O'Connor 2015-01-19 12:41:33 -05:00
parent 301dd092c2
commit c9d97d52c1
1 changed files with 2 additions and 0 deletions

View File

@ -181,6 +181,8 @@ def calc():
noteCall(cur, subfuncs, insnaddr, calladdr, 0)
elif insn.startswith('calll'):
noteCall(cur, subfuncs, insnaddr, calladdr, stackusage + 4)
elif insn.startswith('callw'):
noteCall(cur, subfuncs, insnaddr, calladdr, stackusage + 2)
else:
print("unknown call", ref)
noteCall(cur, subfuncs, insnaddr, calladdr, stackusage)