Sample Video Frame
Exercise 4: Using a Debugger
This is a video-focused exercise where I show you how to use the debugger that comes with your computer to debug your programs, detect errors, and even debug processes that are currently running. Please watch the accompanying video to learn more about this topic.
GDB Tricks
Here's a list of simple tricks you can do with GNU Debugger (GDB):
gdb --args [PROGRAM]: Normally,gdbtakes arguments you give it and assumes they are for itself. Using--argspasses them to the program.- thread apply all bt: Dump a backtrace for all threads. It's very useful.
gdb --batch --ex run --ex bt --ex q --args [PROGRAM] [ARGS]: Run the program so that if it bombs, you get a backtrace.
Register for Learn C the Hard Way
Register today for the course and get the all currently available videos and lessons, plus all future modules for no extra charge.