aboutsummaryrefslogtreecommitdiff
path: root/gdb/p-valprint.c
diff options
context:
space:
mode:
authorPierre Muller <muller@sourceware.org>2011-02-18 14:17:38 +0000
committerPierre Muller <muller@sourceware.org>2011-02-18 14:17:38 +0000
commit13163d8050012d1c79f1ec764c1f621aa47f1c27 (patch)
treeb0ddb628cd5fea1884b8b4c94c3dfb1823aaab79 /gdb/p-valprint.c
parentb434a28f71a481451dbd0719c6ca3fdf072d9407 (diff)
downloadgdb-13163d8050012d1c79f1ec764c1f621aa47f1c27.zip
gdb-13163d8050012d1c79f1ec764c1f621aa47f1c27.tar.gz
gdb-13163d8050012d1c79f1ec764c1f621aa47f1c27.tar.bz2
* c-valprint.c (c_val_print): Add embedded_offset to address
for arrays of unspecified length. * p-valprint.c (pascal_val_print): Likewise.
Diffstat (limited to 'gdb/p-valprint.c')
-rw-r--r--gdb/p-valprint.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/gdb/p-valprint.c b/gdb/p-valprint.c
index fc50e2a..ee76542 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: