This is the mail archive of the gcc-patches@gcc.gnu.org mailing list for the GCC project.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]
Other format: [Raw text]

[lto][patch] fix bug


2008-08-20  Rafael Avila de Espindola  <espindola@google.com>

	* lto-section-out.c (produce_asm_for_decls): Only destroy OB after we
	are done with it.

Cheers,
-- 
Rafael Avila de Espindola

Google Ireland Ltd.
Gordon House
Barrow Street
Dublin 4
Ireland

Registered in Dublin, Ireland
Registration Number: 368047
diff --git a/gcc/lto-section-out.c b/gcc/lto-section-out.c
index bccb957..f7ab910 100644
--- a/gcc/lto-section-out.c
+++ b/gcc/lto-section-out.c
@@ -1109,7 +1109,6 @@ produce_asm_for_decls (void)
 #endif
 
   /* Deallocate memory and clean up.  */
-  destroy_output_block (ob);
 
   htab_delete (out_state->field_decl_hash_table);
   htab_delete (out_state->fn_decl_hash_table);
@@ -1128,6 +1127,8 @@ produce_asm_for_decls (void)
   /* Finish cleanup. */
   htab_delete (ob->main_hash_table);
 
+  destroy_output_block (ob);
+
   VEC_free (tree, heap, out_state->field_decls);
   VEC_free (tree, heap, out_state->fn_decls);
   VEC_free (tree, heap, out_state->var_decls);

Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]