[英]How to debug with gdb when using exec functions
How to debug when using exec functions? 使用exec函数时如何调试? For example, I set a breakpoint at this line execl("/home/hel/a.out", "a.out", arg1, arg2, NULL);
例如,我在这行execl("/home/hel/a.out", "a.out", arg1, arg2, NULL);
处设置一个断点execl("/home/hel/a.out", "a.out", arg1, arg2, NULL);
How can I debug a.out? 如何调试a.out?
In a separate debug session, like this: 在一个单独的调试会话中,如下所示:
$ gdb /home/hel/a.out
(gdb) run arg1 arg2
Isn't this obvious? 这不是很明显吗?
声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.