Fix SIGILL in dynamic linker when calling dlopen()
On ARM/Android (svr4), if /system/bin/linker is stripped of symbols, and its rtld_db_dlactivity() function is implemented as Thumb, then enable_break() needs to preserve the LSB of sym_addr when calling create_solib_event_breakpoint(), so that a Thumb software break- point is used instead of an ARM software breakpoint (which causes a SIGILL.) Additionally, as part of the bookkeeping for this change, we need to distinguish between the requested address, versus the placed address, in bp_target_info. Finally, we also fix a minor but requisite bug in arm_adjust_breakpoint_address(), where we need to remove the LSB of bpaddr, since it serves as a flag and isn't properly part of the address where the breakpoint should be placed. Bug: http://code.google.com/p/android/issues/detail?id=37147 Signed-off-by:Ryan V. Bissell <rbissell@nvidia.com>
Loading
Please sign in to comment