From a74d7e323498f3235ad3fe84b9ae5e5547f26f8e Mon Sep 17 00:00:00 2001 From: Pierre Muller Date: Fri, 18 Feb 2011 14:17:37 +0000 Subject: * c-valprint.c (c_val_print): Add embedded_offset to address for arrays of unspecified length. * p-valprint.c (pascal_val_print): Likewise. --- gdb/p-valprint.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'gdb/p-valprint.c') diff --git a/gdb/p-valprint.c b/gdb/p-valprint.c index fc50e2a3140..ee765421eeb 100644 --- a/gdb/p-valprint.c +++ b/gdb/p-valprint.c @@ -128,7 +128,7 @@ pascal_val_print (struct type *type, const gdb_byte *valaddr, break; } /* Array of unspecified length: treat like pointer to first elt. */ - addr = address; + addr = address + embedded_offset; goto print_unpacked_pointer; case TYPE_CODE_PTR: -- cgit v1.2.1