binutils-gdb/gdb/tui
Simon Marchi 7acd011bef tui: Simplify tui_alloc_content
I stumbled upon this while doing some cxx-conversion work.  Since the
x-family alloc functions throw on failure, it is useless to test their
result for failure.  The else branch of != NULL is basically dead code.

I changed the type of element_block_ptr to struct tui_win_element, which
seems obvious (this is actually what raised the flag, casting the result
of xmalloc to struct tui_win_element* wouldn't work).

gdb/ChangeLog:

	* tui/tui-data.c (tui_alloc_content): Don't check xmalloc
	result.  Change type of element_block_ptr.  Change allocation to
	use XNEWVEC.
2015-10-26 12:58:32 -04:00
..
ChangeLog-1998-2003
tui-command.c
tui-command.h
tui-data.c tui: Simplify tui_alloc_content 2015-10-26 12:58:32 -04:00
tui-data.h
tui-disasm.c Replace some xmalloc-family functions with XNEW-family ones 2015-08-26 17:18:12 -04:00
tui-disasm.h
tui-file.c Add some more casts (2/2) 2015-09-25 14:08:07 -04:00
tui-file.h
tui-hooks.c
tui-hooks.h
tui-interp.c Replace "struct continuation" mechanism by something more extensible 2015-09-09 18:24:00 +01:00
tui-io.c More char constification 2015-10-13 19:40:50 +01:00
tui-io.h
tui-layout.c Add some more casts (2/2) 2015-09-25 14:08:07 -04:00
tui-layout.h
tui-out.c Add some more casts (2/2) 2015-09-25 14:08:07 -04:00
tui-regs.c gdb/tui: Remove casts of NULL during assignment. 2015-09-04 16:50:41 +01:00
tui-regs.h
tui-source.c Add casts to memory allocation related calls 2015-09-25 14:08:06 -04:00
tui-source.h
tui-stack.c
tui-stack.h
tui-win.c gdb/tui: Remove casts of NULL during assignment. 2015-09-04 16:50:41 +01:00
tui-win.h
tui-windata.c gdb/tui: Remove casts of NULL during assignment. 2015-09-04 16:50:41 +01:00
tui-windata.h
tui-wingeneral.c gdb/tui: Remove casts of NULL during assignment. 2015-09-04 16:50:41 +01:00
tui-wingeneral.h
tui-winsource.c
tui-winsource.h
tui.c
tui.h