debugging - 如何在不停止运行程序的情况下关闭gdb连接

标签 debugging gdb gdbserver

有没有办法在不停止/退出正在运行的程序的情况下退出 gdb 连接?我需要在 gdb 连接关闭后继续运行程序。

最佳答案

Is there a way to exit from gdb connnection without stopping / exiting running program ?


(gdb) help detach
Detach a process or file previously attached.
If a process, it is no longer traced, and it continues its execution.  If
you were debugging a file, the file is closed and gdb no longer accesses it.

List of detach subcommands:

detach checkpoint -- Detach from a checkpoint (experimental)
detach inferiors -- Detach from inferior ID (or list of IDS)

Type "help detach" followed by detach subcommand name for full documentation.
Type "apropos word" to search for commands related to "word".
Command name abbreviations are allowed if unambiguous.

关于debugging - 如何在不停止运行程序的情况下关闭gdb连接,我们在Stack Overflow上找到一个类似的问题: https://stackoverflow.com/questions/38094488/

相关文章:

visual-studio - 使用不是与二进制文件同时生成的 pdb 文件进行调试。是否可以?

Delphi App调试时出现 "No Debug Info"

c ->> 轮类运算符(operator)没有按预期工作

linux - GDB 不会介入一个文件之外的功能

c++ - 远程调试问题

c# - 什么是 "Async Pinned Handle"?

c# - VS2008 C# 反射调用方法的异常

c - 告诉GDB使用8个字节作为指针

docker - 如何在 Alpine Docker 镜像上安装 gdbserver 包?

linux - 如何使用 gdbserver 进行远程调试?