mirror of
https://github.com/cemu-project/idapython.git
synced 2024-12-01 05:24:18 +01:00
idautils.py: added qword support for GetDataList()
This commit is contained in:
parent
5e0deab556
commit
45099f4ad4
@ -244,16 +244,16 @@ def GetDataList(ea, count, itemsize=1):
|
|||||||
"""
|
"""
|
||||||
Get data list - INTERNAL USE ONLY
|
Get data list - INTERNAL USE ONLY
|
||||||
"""
|
"""
|
||||||
getdata = None
|
|
||||||
|
|
||||||
if itemsize == 1:
|
if itemsize == 1:
|
||||||
getdata = idaapi.get_byte
|
getdata = idaapi.get_byte
|
||||||
if itemsize == 2:
|
elif itemsize == 2:
|
||||||
getdata = idaapi.get_word
|
getdata = idaapi.get_word
|
||||||
if itemsize == 4:
|
elif itemsize == 4:
|
||||||
getdata = idaapi.get_long
|
getdata = idaapi.get_long
|
||||||
|
elif itemsize == 8:
|
||||||
assert getdata, "Invalid data size! Must be 1, 2 or 4"
|
getdata = idaapi.get_qword
|
||||||
|
else:
|
||||||
|
raise ValueError, "Invalid data size! Must be 1, 2, 4 or 8"
|
||||||
|
|
||||||
for curea in xrange(ea, ea+itemsize*count, itemsize):
|
for curea in xrange(ea, ea+itemsize*count, itemsize):
|
||||||
yield getdata(curea)
|
yield getdata(curea)
|
||||||
|
Loading…
Reference in New Issue
Block a user