I try to print the contents of an array like this, and it's successful:
p/x t->arr
$1 = {0x63, 0x61, 0x74, 0x31, 0x2e, 0x6a, 0x70, 0x67, 0x0 <repeats 248 times>}
However, when I try a different way like this:
(gdb) p &t->arr
$2 = (char (*)[256]) 0x60c4d0
p/100x *0x60c4d0
Item count other than 1 is meaningless in "print" command.
t->arr is defined as arr[256] in the struct. Do I do something wrong?
p/100xwill do?p/100x (char *)*0x60c4d0? So that gdb knows it is schar *at the address. I've never used thep/#xsyntax.