4

I'm using Chrome. I have never seen the Debug button but only the Run button on the top line in my online IDE. How to make the Debug button out?

Every time I press the Run button, the bottom terminal always displays the same words no matter what I click or type in or how many break points I set, and neither the buttons on the right panel work. What should I do?

I've read the suggested post. The issue is not solved in that post, either.

Thank you!

GNU debug not working

2
5

I had the same problem. The only way I've been able to use the graphical interface is to run debug50 ./programname from the terminal.

An alternative would be to use gdb from the terminal which there's a CS50 section on: https://www.youtube.com/watch?v=y5JmQItfFck

1

Google "cs50 gdb youtube" and you will find two helpful videos explaining how to use the debugger from the command line. It's much more reliable, and has the added benefit of being a tool that will always be available to you in the future even if you do not use the Cloud9 IDE for development.

Basically, to debug myprog with a breakpoint at myfunc, passing arguments arg1 and arg2, do the following:

gdb ./myprog
break myfunc
run arg1 arg2

To debug functions in multiple files, set your breakpoints and then as you are stepping through statements with n, pay attention and when you get to the line that calls the externally-defined function, step into it with s instead.

1
  • Thanks! The command mode works. But the GNU debugger is still not working. I've updated the question. Thank you! – Kevin King Aug 25 '16 at 16:14

You must log in to answer this question.

Not the answer you're looking for? Browse other questions tagged .