diff options
author | Roland McGrath <roland@redhat.com> | 2010-01-26 12:37:57 -0800 |
---|---|---|
committer | Roland McGrath <roland@redhat.com> | 2010-01-26 12:37:57 -0800 |
commit | 9368734e8db693bc2d936ecfaa27f812b5b5dd42 (patch) | |
tree | 381bf3eceef58e822d798aa671b71a8f4a2dc6ae /loc2c-test.c | |
parent | 6390a48a6dfb88c9692af877e1767ce6cc8030d0 (diff) | |
download | systemtap-steved-9368734e8db693bc2d936ecfaa27f812b5b5dd42.tar.gz systemtap-steved-9368734e8db693bc2d936ecfaa27f812b5b5dd42.tar.xz systemtap-steved-9368734e8db693bc2d936ecfaa27f812b5b5dd42.zip |
Fix PC arithmetic for CFI in loc2c-test.
* loc2c-test.c (main): Correctly bias PC passed to dwarf_cfi_addrframe.
Diffstat (limited to 'loc2c-test.c')
-rw-r--r-- | loc2c-test.c | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/loc2c-test.c b/loc2c-test.c index 9d4973ed..6631252c 100644 --- a/loc2c-test.c +++ b/loc2c-test.c @@ -556,7 +556,7 @@ main (int argc, char **argv) if (cfi != NULL) { Dwarf_Frame *frame = NULL; - if (dwarf_cfi_addrframe (cfi, pc, &frame) == 0) + if (dwarf_cfi_addrframe (cfi, pc - bias, &frame) == 0) dwarf_frame_cfa (frame, &cfa_ops, &cfa_nops); } if (cfa_ops == NULL) @@ -565,7 +565,7 @@ main (int argc, char **argv) if (cfi != NULL) { Dwarf_Frame *frame = NULL; - if (dwarf_cfi_addrframe (cfi, pc, &frame) == 0) + if (dwarf_cfi_addrframe (cfi, pc - bias, &frame) == 0) dwarf_frame_cfa (frame, &cfa_ops, &cfa_nops); } } |