(gdb) info registers ds
ds 0x7b 123
(gdb) disassemble
Dump of assembler code for function printf@plt:
0x0804831c <+0>: jmp DWORD PTR ds:0x804a008
=> 0x08048322 <+6>: push 0x10
0x08048327 <+11>: jmp 0x80482ec
End of assembler dump.
Run Code Online (Sandbox Code Playgroud)
有人可以告诉我如何将 ds:0x804a008 地址映射到线性地址吗?我可以使用“x/xw 地址”命令吗?如果不清楚,我想知道代码跳转中的第一个 jmp 函数在哪里。
我有gdb的问题,它没有停在一个功能.你能解释为什么以及如何在调用strcpy后停止程序?
grzes@trampek:~/poligon$ gdb ./char_array2
GNU gdb (GDB) 7.2
Copyright (C) 2010 Free Software Foundation, Inc.
License GPLv3+: GNU GPL version 3 or later <http://gnu.org/licenses/gpl.html>
This is free software: you are free to change and redistribute it.
There is NO WARRANTY, to the extent permitted by law. Type "show copying"
and "show warranty" for details.
This GDB was configured as "i686-pc-linux-gnu".
For bug reporting instructions, please see:
<http://www.gnu.org/software/gdb/bugs/>...
Reading symbols from /home/grzes/poligon/char_array2...done.
(gdb) list
1 #include <stdio.h>
2 #include <string.h>
3 …Run Code Online (Sandbox Code Playgroud)