gdb
gdb @ 可以打印地址后面指定长度的字节
(gdb) p * attr2->aspath->data
$5 = 2 '\002'
(gdb) p attr2->aspath->data
$3 = (u_int8_t *) 0x160fa48 "\002\002"
(gdb) p * attr2->aspath->data@12
$11 = "\002\002\000{\001A\000\000\274\246\374\003"
(gdb) p/x * attr2->aspath->data@12
$12 = {0x2, 0x2, 0x0, 0x7b, 0x1, 0x41, 0x0, 0x0, 0xbc, 0xa6, 0xfc, 0x3}
gdb watch 可以一直监视某固定地址的值的变化
gdb watch *0x7ddada4412a
本文来自博客园,作者:开源侠,转载请注明原文链接:https://www.cnblogs.com/cyj22/p/17571960.html
微信公众号:青衫换酒吃