Skip to content

Commit

Permalink
[BUGFIX] Fix lines not starting from the offset (Issue #13)
Browse files Browse the repository at this point in the history
  • Loading branch information
hasherezade committed Jul 17, 2020
1 parent 029d300 commit 2f3f9b8
Showing 1 changed file with 8 additions and 3 deletions.
11 changes: 8 additions & 3 deletions ifl.py
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
#!/usr/bin/env python
#!/usr/bin/env python3
#
# IFL - Interactive Functions List
#
Expand All @@ -10,7 +10,7 @@
"""
CC-BY: hasherezade, run via IDA Pro >= 7.0
"""
__VERSION__ = '1.4'
__VERSION__ = '1.4.1'
__AUTHOR__ = 'hasherezade'

PLUGIN_NAME = "IFL - Interactive Functions List"
Expand Down Expand Up @@ -881,7 +881,12 @@ def _loadFunctionsNames(self, file_name: Optional[str], ext: str) -> Optional[Tu
fn = line.split(delim2) # try old delimiter
if len(fn) < 2:
continue
start = int(fn[0].strip(), 16)
start = 0
try:
start = int(fn[0].strip(), 16)
except ValueError:
# this line doesn't start from an offset, so skip it
continue
func_name = fn[1].strip()
if start < idaapi.get_imagebase(): # it is RVA
start = rva_to_va(start) # convert to VA
Expand Down

0 comments on commit 2f3f9b8

Please sign in to comment.