Вопрос

I am trying to figure out why a program I am using is hanging.

I initially thought the problem was "solved" by running it through GDB but I am getting the exact same symptoms as before - is there any way I can send a signal or something to GDB to print off the stack trace so I can try to see what is happening?

I am using FreeBSD-9.0.

Это было полезно?

Решение 2

I ended up getting a backtrace by creating a coredump using gcore(1) and then starting myprogram with the coredump created in GDB.

Другие советы

You can interrupt a running process within GDB by simply pressing Control-C.

You can then get a backtrace with the backtrace command.

Лицензировано под: CC-BY-SA с атрибуция
Не связан с StackOverflow
scroll top