aboutsummaryrefslogtreecommitdiff
path: root/gdb/dwarf2loc.c
diff options
context:
space:
mode:
Diffstat (limited to 'gdb/dwarf2loc.c')
-rw-r--r--gdb/dwarf2loc.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/gdb/dwarf2loc.c b/gdb/dwarf2loc.c
index 6185a6b..99a18a9 100644
--- a/gdb/dwarf2loc.c
+++ b/gdb/dwarf2loc.c
@@ -1421,7 +1421,7 @@ allocate_piece_closure (struct dwarf2_per_cu_data *per_cu,
c->per_cu = per_cu;
c->n_pieces = n_pieces;
c->addr_size = addr_size;
- c->pieces = XCALLOC (n_pieces, struct dwarf_expr_piece);
+ c->pieces = XCNEWVEC (struct dwarf_expr_piece, n_pieces);
memcpy (c->pieces, pieces, n_pieces * sizeof (struct dwarf_expr_piece));
for (i = 0; i < n_pieces; ++i)