Commit ff5b6492 by Mikael Morin

re PR fortran/44662 (unitialized memory on testcases abstract_type_6.f03 and typebound_call_4.f03)

2010-07-02  Mikael Morin  <mikael@gcc.gnu.org>

	PR fortran/44662
	* decl.c (match_procedure_in_type): Clear structure before using.
	(gfc_match_generic): Ditto.

From-SVN: r161739
parent dfd6ece2
2010-07-02 Mikael Morin <mikael@gcc.gnu.org>
PR fortran/44662
* decl.c (match_procedure_in_type): Clear structure before using.
(gfc_match_generic): Ditto.
2010-07-02 Nathan Froyd <froydnj@codesourcery.com>
* trans-types.h (gfc_add_field_to_struct): Add tree ** parameter.
......
......@@ -7697,8 +7697,8 @@ match_procedure_in_type (void)
}
/* Construct the data structure. */
memset (&tb, 0, sizeof (tb));
tb.where = gfc_current_locus;
tb.is_generic = 0;
/* Match binding attributes. */
m = match_binding_attributes (&tb, false, false);
......@@ -7856,6 +7856,9 @@ gfc_match_generic (void)
ns = block->f2k_derived;
gcc_assert (block && ns);
memset (&tbattr, 0, sizeof (tbattr));
tbattr.where = gfc_current_locus;
/* See if we get an access-specifier. */
m = match_binding_attributes (&tbattr, true, false);
if (m == MATCH_ERROR)
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment