godump.c (go_format_type): Correct length of name added to obstack for anonymous field.

* godump.c (go_format_type): Correct length of name added to
	obstack for anonymous field.

From-SVN: r174465
This commit is contained in:
Ian Lance Taylor 2011-05-31 05:34:45 +00:00 committed by Ian Lance Taylor
parent dd7b175ec3
commit 5a880d5d95
2 changed files with 6 additions and 1 deletions

View File

@ -1,3 +1,8 @@
2011-05-30 Ian Lance Taylor <iant@google.com>
* godump.c (go_format_type): Correct length of name added to
obstack for anonymous field.
2011-05-30 Kaz Kojima <kkojima@gcc.gnu.org>
PR target/49186

View File

@ -700,7 +700,7 @@ go_format_type (struct godump_container *container, tree type,
{
char buf[100];
obstack_grow (ob, "Godump_", 2);
obstack_grow (ob, "Godump_", 7);
snprintf (buf, sizeof buf, "%d", i);
obstack_grow (ob, buf, strlen (buf));
i++;