小编afs*_*zal的帖子

附加到另一个进程时如何在gdb中设置断点

我有一个 C 程序,它编写了一个非常复杂的脚本来运行它。我需要使用gdb. 我试图运行脚本并将 gdb 附加到它的进程,但是我无法设置我需要的断点:

$ gdb median.o 27944
GNU gdb (Ubuntu 7.7.1-0ubuntu5~14.04.2) 7.7.1
Copyright (C) 2014 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 "x86_64-linux-gnu".
Type "show configuration" for configuration details.
For bug reporting instructions, please …
Run Code Online (Sandbox Code Playgroud)

c debugging gdb

3
推荐指数
1
解决办法
5827
查看次数

标签 统计

c ×1

debugging ×1

gdb ×1