summaryrefslogtreecommitdiff
path: root/view/sharedcache/core/MachO.h
diff options
context:
space:
mode:
authorMason Reed <mason@vector35.com>2025-04-06 21:00:43 -0400
committerMason Reed <mason@vector35.com>2025-04-06 21:11:00 -0400
commit833375c0199d4e7c2555e6e9f14862ddc3ca120c (patch)
tree5cebee81848306b30d5b205d0116f1bcdad7737c /view/sharedcache/core/MachO.h
parentc22d54c5d95f4d23629484579414387b0c7503ee (diff)
[SharedCache] Prevent some unneeded copies when processing
Also swapped out CacheEntry::m_images to a vector as its never actually used as a lookup
Diffstat (limited to 'view/sharedcache/core/MachO.h')
-rw-r--r--view/sharedcache/core/MachO.h5
1 files changed, 3 insertions, 2 deletions
diff --git a/view/sharedcache/core/MachO.h b/view/sharedcache/core/MachO.h
index 37b82915..8508edbf 100644
--- a/view/sharedcache/core/MachO.h
+++ b/view/sharedcache/core/MachO.h
@@ -64,8 +64,9 @@ struct SharedCacheMachOHeader
// TODO: Replace view with address size?
std::vector<CacheSymbol> ReadSymbolTable(BinaryNinja::BinaryView& view, VirtualMemory& vm) const;
- std::optional<CacheSymbol> AddExportTerminalSymbol(
- const std::string& symbolName, const uint8_t* current, const uint8_t* end) const;
+ bool AddExportTerminalSymbol(
+ std::vector<CacheSymbol>& symbols, const std::string& symbolName, const uint8_t* current,
+ const uint8_t* end) const;
bool ProcessLinkEditTrie(std::vector<CacheSymbol>& symbols, const std::string& currentText, const uint8_t* begin,
const uint8_t* current, const uint8_t* end) const;