This is the mail archive of the
gdb-patches@sourceware.org
mailing list for the GDB project.
[PATCH 06/40] remove erroneous return from setup_user_args
- From: Tom Tromey <tromey at redhat dot com>
- From: Tom Tromey <tromey at redhat dot com>
- To: gdb-patches at sourceware dot org
- Date: Thu, 09 May 2013 12:49:29 -0600
- Subject: [PATCH 06/40] remove erroneous return from setup_user_args
- References: <cover dot 1368124285 dot git dot tromey at redhat dot com>
This fixes setup_user_args to drop a useless and confusing "return".
* cli/cli-script.c (setup_user_args): Don't return after error.
---
gdb/cli/cli-script.c | 7 ++-----
1 file changed, 2 insertions(+), 5 deletions(-)
diff --git a/gdb/cli/cli-script.c b/gdb/cli/cli-script.c
index 3b24799..43fd479 100644
--- a/gdb/cli/cli-script.c
+++ b/gdb/cli/cli-script.c
@@ -689,11 +689,8 @@ setup_user_args (char *p)
int bsquote = 0;
if (arg_count >= MAXUSERARGS)
- {
- error (_("user defined function may only have %d arguments."),
- MAXUSERARGS);
- return old_chain;
- }
+ error (_("user defined function may only have %d arguments."),
+ MAXUSERARGS);
/* Strip whitespace. */
while (*p == ' ' || *p == '\t')
--
1.8.1.4