aboutsummaryrefslogtreecommitdiff
path: root/gdb
diff options
context:
space:
mode:
authorJeff Law <law@redhat.com>1995-10-03 03:48:32 +0000
committerJeff Law <law@redhat.com>1995-10-03 03:48:32 +0000
commita25ffb081fe412c933d59383add68d831e03e5f2 (patch)
treeee55336907d50caa733042b0b10fcffffd1d4e8d /gdb
parent3994972d62e654c0b26559c7cf39c350e3d1ee19 (diff)
downloadgdb-a25ffb081fe412c933d59383add68d831e03e5f2.zip
gdb-a25ffb081fe412c933d59383add68d831e03e5f2.tar.gz
gdb-a25ffb081fe412c933d59383add68d831e03e5f2.tar.bz2
* top.c (build_command_line): Demand arguments for if/while
commands.
Diffstat (limited to 'gdb')
-rw-r--r--gdb/ChangeLog5
-rw-r--r--gdb/top.c3
2 files changed, 8 insertions, 0 deletions
diff --git a/gdb/ChangeLog b/gdb/ChangeLog
index b481540..29840d4 100644
--- a/gdb/ChangeLog
+++ b/gdb/ChangeLog
@@ -1,3 +1,8 @@
+Mon Oct 2 21:45:44 1995 Jeff Law (law@hurl)
+
+ * top.c (build_command_line): Demand arguments for if/while
+ commands.
+
Mon Oct 2 13:08:01 1995 Jason Molenda (crash@phydeaux.cygnus.com)
* Makefile.in (X11_CFLAGS): Set only to @X_INCDIR@.
diff --git a/gdb/top.c b/gdb/top.c
index 20c1865..1d6b0c5 100644
--- a/gdb/top.c
+++ b/gdb/top.c
@@ -649,6 +649,9 @@ build_command_line (type, args)
{
struct command_line *cmd;
+ if (args == NULL)
+ error ("if/while commands require arguments.\n");
+
cmd = (struct command_line *)xmalloc (sizeof (struct command_line));
cmd->next = NULL;
cmd->control_type = type;