Skip to content

Commit

Permalink
Merge pull request #2666 from crytic/dev-fix-slither-read-storage
Browse files Browse the repository at this point in the history
Fix slither-read-storage crash when a structure has only other structs as fields
  • Loading branch information
smonicas authored Feb 21, 2025
2 parents b392536 + 46f3caf commit 88fdafb
Showing 1 changed file with 1 addition and 0 deletions.
1 change: 1 addition & 0 deletions slither/tools/read_storage/read_storage.py
Original file line number Diff line number Diff line change
Expand Up @@ -578,6 +578,7 @@ def _find_struct_var_slot(
slot = int.from_bytes(slot_as_bytes, "big")
offset = 0
type_to = ""
size = 0
for var in elems:
var_type = var.type
if isinstance(var_type, ElementaryType):
Expand Down

0 comments on commit 88fdafb

Please sign in to comment.