Skip to content

Commit

Permalink
Fix README
Browse files Browse the repository at this point in the history
  • Loading branch information
mahaloz committed May 30, 2024
1 parent 95c5b93 commit 3840ade
Show file tree
Hide file tree
Showing 2 changed files with 3 additions and 1 deletion.
2 changes: 1 addition & 1 deletion README.md
Original file line number Diff line number Diff line change
Expand Up @@ -75,5 +75,5 @@ import json
my_func = Function(name="my_func", addr=0x4000, size=0x10)
json_str = my_func.dumps(fmt="json")
loaded_dict = json.loads(json_str) # now loadable through normal JSON parsing
print(json_str)
loaded_func = Function.loads(json_str, fmt="json")
```
2 changes: 2 additions & 0 deletions libbs/artifacts/func.py
Original file line number Diff line number Diff line change
Expand Up @@ -196,6 +196,7 @@ def __init__(
self,
addr: int = None,
size: int = None,
name: str = None,
header: Optional[FunctionHeader] = None,
stack_vars: Optional[Dict[int, StackVariable]] = None,
dec_obj: Optional[object] = None,
Expand All @@ -205,6 +206,7 @@ def __init__(
self.addr = addr
self.size = size
self.header = header
self.name = name
self.stack_vars: Dict[int, StackVariable] = stack_vars or {}

# a special property which can only be set while running inside the decompiler.
Expand Down

0 comments on commit 3840ade

Please sign in to comment.