Skip to content

Commit f4c25e1

Browse files
committed
remove path that sets rebase_exec to false in posixDYLD
1 parent 3da761c commit f4c25e1

File tree

1 file changed

+1
-18
lines changed

1 file changed

+1
-18
lines changed

lldb/source/Plugins/DynamicLoader/POSIX-DYLD/DynamicLoaderPOSIXDYLD.cpp

Lines changed: 1 addition & 18 deletions
Original file line numberDiff line numberDiff line change
@@ -108,24 +108,7 @@ void DynamicLoaderPOSIXDYLD::DidAttach() {
108108
// if we dont have a load address we cant re-base
109109
bool rebase_exec = load_offset != LLDB_INVALID_ADDRESS;
110110

111-
// if we have a valid executable
112-
if (executable_sp.get()) {
113-
lldb_private::ObjectFile *obj = executable_sp->GetObjectFile();
114-
if (obj) {
115-
// don't rebase if the module already has a load address
116-
Target &target = m_process->GetTarget();
117-
Address addr = obj->GetImageInfoAddress(&target);
118-
addr_t load_addr = addr.GetLoadAddress(&target);
119-
if (load_addr != LLDB_INVALID_ADDRESS)
120-
rebase_exec = false;
121-
}
122-
} else {
123-
// no executable, nothing to re-base
124-
rebase_exec = false;
125-
}
126-
127-
// if the target executable should be re-based
128-
if (rebase_exec || IsCoreFile()) {
111+
if (rebase_exec) {
129112
ModuleList module_list;
130113

131114
module_list.Append(executable_sp);

0 commit comments

Comments
 (0)