This is the mail archive of the gdb-testers@sourceware.org mailing list for the GDB 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]

[binutils-gdb] Use new/delete instead of malloc/free-based functions


*** TEST RESULTS FOR COMMIT 5486f16481dffa1c1a0d1fd9e38b97e3678078ed ***

Author: Simon Marchi <simon.marchi@polymtl.ca>
Branch: master
Commit: 5486f16481dffa1c1a0d1fd9e38b97e3678078ed

Use new/delete instead of malloc/free-based functions

The following patches introduce C++ vectors and strings as fields of the
various ui_out structures.  We therefore need to use new/delete so that
their contructor/destructor is called.  I find it simpler to change all
the allocations in a separate preliminary patch, rather than in each
individual patch.

gdb/ChangeLog:

	* cli-out.c (cli_uiout_dtor): Use delete instead of xfree.
	(cli_out_new): Use new instead of XNEW.
	* mi/mi-out.c (mi_out_data_dtor): Use delete instead of xfree.
	(mi_out_new): Use new instead of XNEW.
	* tui/tui-out.c (tui_out_new): Likewise.
	* ui-out.c (push_level): Likewise.
	(pop_level): Use delete instead of xfree.
	(clear_header_list): Use delete instead of xfree.
	(append_header_to_list): Use new instead of XNEW.
	(ui_out_new): Likewise.


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