gdb: Add cleanup to avoid memory leak on error.
authorAndrew Burgess <andrew.burgess@embecosm.com>
Wed, 20 May 2015 22:51:23 +0000 (00:51 +0200)
committerAndrew Burgess <andrew.burgess@embecosm.com>
Thu, 21 May 2015 18:49:00 +0000 (20:49 +0200)
commitc1b009eed88d41b22c9faf68d0dc15967292f6c9
tree0c1331c45e60f5c9b3f0b36df76ea133180bd745
parent880d1e40c771e4a389d0b29bf196b50f1b696ea9
gdb: Add cleanup to avoid memory leak on error.

Use cleanup to avoid leaking memory if an error occurs during tui
start up.

gdb/ChangeLog:

* tui/tui-layout.c (tui_set_layout_for_display_command): Ensure
buf_ptr is freed.
gdb/ChangeLog
gdb/tui/tui-layout.c