Вопрос

I am using pdb to debug a python program, and the python program uses a module written by C. I want to use "step" command to enter the function in the module written by C, but I find this operation can't be successful. Is there any method to use pdb debug module written by C? Thanks in advance!

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

Решение

pdb won't allow you to debug modules written in C. You can however use gdb to debug errors you might be encountering in C code.

To launch a Python script using gdb you can use the following command:

gdb python

and then to execute your script:

(gdb) run <myscript>.py
Лицензировано под: CC-BY-SA с атрибуция
Не связан с StackOverflow
scroll top