GDB运行命令后(即使有断点设置)立即退出返回到终端 [英] GDB immediately exits back to terminal after run command (even with breakpoints set)

查看:1014
本文介绍了GDB运行命令后(即使有断点设置)立即退出返回到终端的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

程序编译

 的gcc -o -g DynamicData main.o中list.o

和广发行开辟为

  GDB DynamicData

似乎并没有工作。当我键入​​运行,GDB只是返回我的主要终端。甚至当我设置断点,它只是退出。没有错误,这是怪异的一部分,我一直没能在网上找到的任何东西。

真的需要找到的核心转储在我的code发生(这是由于在几天!),所以任何帮助将大大AP preciated!

运行的SunOS 5.10的机器上是否有帮助


解决方案

  

当我键入运行,GDB只是返回我的主要终端。


请更precise。有两种方法您的语句可以跨preTED:


  1. 只要你键入运行,你将返回到(GDB)提示符。

  2. 只要你键入运行,GDB退出并返回到shell提示符。

在这两种情况下,看来是GDB您的机器上破(但它究竟是如何打破,两种情况之间为什么会有所不同)。

您可以尝试使用Solaris系统调试器 DBX ,这是不太可能被打破,或向您的系统管理员得到GDB安装固定。

Program compiled with

gcc -g -o DynamicData main.o list.o

and opened in GDB as

gdb DynamicData

doesn't seem to work. As soon as I type run, GDB just returns to my main terminal. Even when I set breakpoints it just exits. There's no error, which is the weird part, and I haven't been able to find anything online.

Really need to find where the coredump is happening in my code (it's due in a few days!) so any help would be greatly appreciated!

Running on a SunOS 5.10 machine if that helps

解决方案

As soon as I type run, GDB just returns to my main terminal.

Please be more precise. There are two ways your statement can be interpreted:

  1. As soon as you type run, you are returned to the (gdb) prompt.
  2. As soon as you type run, GDB exits and returns you to the shell prompt.

In either case, it appears that GDB is broken on your machine (but exactly how it's broken and why would differ between the two cases).

You could try to use the Solaris system debugger dbx, which is less likely to be broken, or talk to your system administrator to get GDB installation fixed.

这篇关于GDB运行命令后(即使有断点设置)立即退出返回到终端的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆