This is the mail archive of the
gdb-patches@sourceware.org
mailing list for the GDB project.
Re: [patch][python] 2 of 5 - Frame filter MI code changes.
- From: Tom Tromey <tromey at redhat dot com>
- To: Phil Muldoon <pmuldoon at redhat dot com>
- Cc: "gdb-patches\ at sourceware dot org" <gdb-patches at sourceware dot org>
- Date: Mon, 06 May 2013 14:42:52 -0600
- Subject: Re: [patch][python] 2 of 5 - Frame filter MI code changes.
- References: <51876882 dot 3010301 at redhat dot com>
>>>>> "Phil" == Phil Muldoon <pmuldoon@redhat.com> writes:
Phil> @@ -52,14 +78,43 @@ mi_cmd_stack_list_frames (char *command, char **argv, int argc)
Phil> + if ((argc > 3) || (argc == 2 && oind) || (argc == 1 && ! oind))
Phil> + error (_("-stack-list-frames: Usage: [--no-frame-filters] [FRAME_LOW FRAME_HIGH]"));
Phil> - if (argc == 2)
Phil> + if (argc == 3 || argc == 2)
It seems to me that these checks should use oind rather than argc.
Then they would be simpler.
As it is I think they are wrong for the weird but accepted input:
-stack-list-frames --no-frame-filters --no-frame-filters 0 15
Tom