How to display memory contents in GDB


I am using GDB and would like to know how to print the memory location.  For example,

if a pointer has value 0xf22323 then I want to know what is actually there in the memory.

Who is Participating?
jkrConnect With a Mentor Commented:
Just type

x 0xf22323

('x' is short for 'examine')

See also ("Debugging Under Unix: gdb Tutorial") and ("RMS's gdb Debugger Tutorial") with ("6.1 How do I examine memory?") in particular
All Courses

From novice to tech pro — start learning today.