summaryrefslogtreecommitdiff
path: root/languagerepresentation.cpp
diff options
context:
space:
mode:
Diffstat (limited to 'languagerepresentation.cpp')
-rw-r--r--languagerepresentation.cpp7
1 files changed, 6 insertions, 1 deletions
diff --git a/languagerepresentation.cpp b/languagerepresentation.cpp
index 6e3bf01b..0930c0b8 100644
--- a/languagerepresentation.cpp
+++ b/languagerepresentation.cpp
@@ -387,8 +387,13 @@ BNDisassemblyTextLine* LanguageRepresentationFunctionType::GetFunctionTypeTokens
}
-void LanguageRepresentationFunctionType::FreeLinesCallback(void*, BNDisassemblyTextLine* lines, size_t)
+void LanguageRepresentationFunctionType::FreeLinesCallback(void*, BNDisassemblyTextLine* lines, size_t count)
{
+ for (size_t i = 0; i < count; i++)
+ {
+ InstructionTextToken::FreeInstructionTextTokenList(lines[i].tokens, lines[i].count);
+ Tag::FreeTagList(lines[i].tags, lines[i].tagCount);
+ }
delete[] lines;
}