diff options
Diffstat (limited to 'binaryview.cpp')
| -rw-r--r-- | binaryview.cpp | 3 |
1 files changed, 2 insertions, 1 deletions
diff --git a/binaryview.cpp b/binaryview.cpp index ad73cc33..0d3e51c3 100644 --- a/binaryview.cpp +++ b/binaryview.cpp @@ -1611,7 +1611,8 @@ std::vector<Ref<Relocation>> BinaryView::GetRelocationsAt(uint64_t addr) const { size_t count = 0; BNRelocation** relocations = BNGetRelocationsAt(m_object, addr, &count); - std::vector<Ref<Relocation>> result(count); + std::vector<Ref<Relocation>> result; + result.reserve(count); for (size_t i = 0; i < count; i++) { result.push_back(new Relocation(relocations[i])); |
