Skip to content

Commit

Permalink
Update print_cil_from_dn_file.py (#126)
Browse files Browse the repository at this point in the history
  • Loading branch information
doomedraven authored Sep 26, 2024
1 parent e195dd0 commit 34cb655
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion scripts/print_cil_from_dn_file.py
Original file line number Diff line number Diff line change
Expand Up @@ -56,7 +56,7 @@ def read_dotnet_user_string(pe: dnfile.dnPE, token: StringToken) -> Union[str, I
except UnicodeDecodeError as e:
return InvalidToken(token.value)

if user_string is None or user_string.value is None:
if user_string is None or (isinstance(user_string, bytes) or user_string.value is None):
return InvalidToken(token.value)

return user_string.value
Expand Down

0 comments on commit 34cb655

Please sign in to comment.