summaryrefslogtreecommitdiff
path: root/python/debuginfo.py
diff options
context:
space:
mode:
authorRusty Wagner <rusty.wagner@gmail.com>2023-01-26 16:37:39 -0500
committerRusty Wagner <rusty.wagner@gmail.com>2023-01-30 11:57:43 -0500
commit6ed8f189b2a0607a13c2a2163d82993ca60d2a19 (patch)
treebec8293f894c664f29edeaa64eddee609aada8b5 /python/debuginfo.py
parenta3939bdec15f9299ae9a681255fa93c47113870a (diff)
Fix Type object leaks
Diffstat (limited to 'python/debuginfo.py')
-rw-r--r--python/debuginfo.py2
1 files changed, 1 insertions, 1 deletions
diff --git a/python/debuginfo.py b/python/debuginfo.py
index f2c1c51f..a8307cae 100644
--- a/python/debuginfo.py
+++ b/python/debuginfo.py
@@ -370,7 +370,7 @@ class DebugInfo(object):
def get_type_by_name(self, parser_name: str, name: str) -> Optional[_types.Type]:
result = core.BNGetDebugTypeByName(self.handle, parser_name, name)
if result is not None:
- return _types.Type(core.BNNewTypeReference(result))
+ return _types.Type(result)
return None
def get_data_variable_by_name(self, parser_name: str, name: str) -> Optional[Tuple[int, _types.Type]]: