summaryrefslogtreecommitdiff
path: root/type.cpp
diff options
context:
space:
mode:
authorGlenn Smith <glenn@vector35.com>2023-11-14 18:35:38 -0500
committerGlenn Smith <glenn@vector35.com>2023-11-14 18:35:38 -0500
commit4025361513068463390900635313910200542556 (patch)
tree2dbfc8ef20c3eae8d849a02d833917dc24b28d28 /type.cpp
parent814d840c8d12dfcfb60a5bf172ea494825fd30c1 (diff)
Fix a number of leaks and bad uses of free in the api
See https://github.com/Vector35/binaryninja-api/issues/4751
Diffstat (limited to 'type.cpp')
-rw-r--r--type.cpp1
1 files changed, 1 insertions, 0 deletions
diff --git a/type.cpp b/type.cpp
index 0e686a0a..4ecbc338 100644
--- a/type.cpp
+++ b/type.cpp
@@ -1909,6 +1909,7 @@ TypeBuilder& TypeBuilder::SetParameters(const std::vector<FunctionParameter>& pa
size_t paramCount = 0;
BNFunctionParameter* paramArray = GetParamArray(params, paramCount);
BNSetFunctionTypeBuilderParameters(m_object, paramArray, paramCount);
+ delete[] paramArray;
return *this;
}