Skip to content

Commit 03b292c

Browse files
committed
mach-o fixes
1 parent 5bfcf28 commit 03b292c

File tree

2 files changed

+3
-3
lines changed

2 files changed

+3
-3
lines changed

src/binary/mach-o.cpp

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -103,7 +103,7 @@ namespace detail {
103103

104104
Result<const char*, internal_error> mach_o::symtab_info_data::get_string(std::size_t index) const {
105105
if(stringtab && index < symtab.strsize) {
106-
return stringtab.get() + index;
106+
return stringtab.unwrap().data() + index;
107107
} else {
108108
return internal_error("can't retrieve symbol from symtab");
109109
}
@@ -287,7 +287,7 @@ namespace detail {
287287
}
288288
print_symbol_table_entry(
289289
entry.unwrap_value(),
290-
stringtab ? stringtab.unwrap_value().get() : nullptr,
290+
stringtab ? stringtab.unwrap_value().data() : nullptr,
291291
symtab.strsize,
292292
j
293293
);

src/binary/mach-o.hpp

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -63,7 +63,7 @@ namespace detail {
6363

6464
struct symtab_info_data {
6565
symtab_command symtab;
66-
std::vector<char> stringtab;
66+
optional<std::vector<char>> stringtab;
6767
Result<const char*, internal_error> get_string(std::size_t index) const;
6868
};
6969

0 commit comments

Comments
 (0)