Skip to content

Commit

Permalink
updated return value in get_go_version
Browse files Browse the repository at this point in the history
  • Loading branch information
sara-rn committed Nov 14, 2023
1 parent e593a3c commit 605a7b4
Showing 1 changed file with 2 additions and 3 deletions.
5 changes: 2 additions & 3 deletions floss/language/identify.py
Original file line number Diff line number Diff line change
Expand Up @@ -137,7 +137,7 @@ def get_if_go_and_version(pe: pefile.PE) -> Tuple[bool, str]:
for go_function in go_functions:
if go_function in section_data:
logger.info("Go binary found, function name %s", go_function)
return True
return True, VERSION_UNKNOWN_OR_NA
except ValueError:
logger.debug(".rdata section not found")

Expand All @@ -149,9 +149,8 @@ def get_if_go_and_version(pe: pefile.PE) -> Tuple[bool, str]:
for go_function in go_functions:
if go_function in section_data:
logger.info("Go binary found, function name %s", go_function)
return True
return True, VERSION_UNKNOWN_OR_NA

return False
return False, VERSION_UNKNOWN_OR_NA


Expand Down

0 comments on commit 605a7b4

Please sign in to comment.