aboutsummaryrefslogtreecommitdiff
path: root/gdb/mi/mi-console.c
diff options
context:
space:
mode:
authorMichael Snyder <msnyder@vmware.com>2010-05-17 20:49:39 +0000
committerMichael Snyder <msnyder@vmware.com>2010-05-17 20:49:39 +0000
commit102040f0d08b06980adf402c17b2f039fee7d23c (patch)
treeef6558f84010ba8af6ee46b4cfddc6d5d24b5752 /gdb/mi/mi-console.c
parentcdb27c12f30352674694895e06f615fd28ebdbec (diff)
downloadgdb-102040f0d08b06980adf402c17b2f039fee7d23c.zip
gdb-102040f0d08b06980adf402c17b2f039fee7d23c.tar.gz
gdb-102040f0d08b06980adf402c17b2f039fee7d23c.tar.bz2
2010-05-17 Michael Snyder <msnyder@vmware.com>
* mi/mi-cmd-break.c: White space. * mi/mi-cmd-env.c: White space. * mi/mi-cmds.c: White space. * mi/mi-cmd-stack.c: White space. * mi/mi-cmd-var.c: White space. * mi/mi-console.c: White space. * mi/mi-getopt.c: White space. * mi/mi-interp.c: White space. * mi/mi-main.c: White space. * mi/mi-out.c: White space. * mi/mi-parse.c: White space.
Diffstat (limited to 'gdb/mi/mi-console.c')
-rw-r--r--gdb/mi/mi-console.c5
1 files changed, 5 insertions, 0 deletions
diff --git a/gdb/mi/mi-console.c b/gdb/mi/mi-console.c
index 80596e4..eb5d074 100644
--- a/gdb/mi/mi-console.c
+++ b/gdb/mi/mi-console.c
@@ -47,6 +47,7 @@ mi_console_file_new (struct ui_file *raw,
{
struct ui_file *ui_file = ui_file_new ();
struct mi_console_file *mi_console = XMALLOC (struct mi_console_file);
+
mi_console->magic = &mi_console_file_magic;
mi_console->raw = raw;
mi_console->buffer = mem_fileopen ();
@@ -62,6 +63,7 @@ static void
mi_console_file_delete (struct ui_file *file)
{
struct mi_console_file *mi_console = ui_file_data (file);
+
if (mi_console->magic != &mi_console_file_magic)
internal_error (__FILE__, __LINE__,
_("mi_console_file_delete: bad magic number"));
@@ -73,6 +75,7 @@ mi_console_file_fputs (const char *buf,
struct ui_file *file)
{
struct mi_console_file *mi_console = ui_file_data (file);
+
if (mi_console->magic != &mi_console_file_magic)
internal_error (__FILE__, __LINE__,
"mi_console_file_fputs: bad magic number");
@@ -90,6 +93,7 @@ mi_console_raw_packet (void *data,
long length_buf)
{
struct mi_console_file *mi_console = data;
+
if (mi_console->magic != &mi_console_file_magic)
internal_error (__FILE__, __LINE__,
_("mi_console_file_transform: bad magic number"));
@@ -116,6 +120,7 @@ static void
mi_console_file_flush (struct ui_file *file)
{
struct mi_console_file *mi_console = ui_file_data (file);
+
if (mi_console->magic != &mi_console_file_magic)
internal_error (__FILE__, __LINE__,
_("mi_console_file_flush: bad magic number"));