Commit ec406889 authored by Simo Melenius's avatar Simo Melenius Committed by Ryan V. Bissell
Browse files

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: default avatarRyan V. Bissell <rbissell@nvidia.com>
parent ccddbccc
Loading
Loading
Loading
Loading
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Please to comment