Print Settings (Debugging with GDB) - sourceware. org GDB prints memory addresses showing the location of stack traces, structure values, pointer values, breakpoints, and so forth, even when it also displays the contents of those addresses The default is on For example, this is what a stack frame display looks like with set print address on:
Debugging with GDB - Print Settings - GNU If you have a pointer and you are not sure where it points, try `set print symbol-filename on' Then you can determine the name and source file location of the variable where it points, using `p a pointer' This interprets the address in symbolic form For example, here GDB shows that a variable ptt points at another variable t, defined in `hi2 c': (gdb) set print symbol-filename on (gdb) p a
Debugging with GDB - Print Settings - University of Nevada, Reno You can use `set print address off' to eliminate all machine dependent displays from the GDB interface For example, with print address off, you should get the same text for backtraces on all machines--whether or not they involve pointer arguments
c - Display value found at given address gdb - Stack Overflow Is this the correct way to read the value of an address in gdb? I was kind of expecting to find a more ascii friendly hex value I am interested in finding the stored string value that is compared against Also do you have a favorite gui tool that you like to use for this type of debugging? I have been thinking about trying ddd
GDB Command Reference - print command - VisualGDB Format If specified, allows overriding the output format used by the command Valid format specifiers are: o - octal x - hexadecimal u - unsigned decimal t - binary f - floating point a - address c - char s - string Examples We will demonstrate the print command using a basic C++ program that prints its own command-line arguments: