This is the mail archive of the
gdb-patches@sourceware.org
mailing list for the GDB project.
Re: [PATCH V2 3/9] New commands `enable probe' and `disable probe'.
- From: Sergio Durigan Junior <sergiodj at redhat dot com>
- To: "Jose E. Marchesi" <jose dot marchesi at oracle dot com>
- Cc: gdb-patches at sourceware dot org
- Date: Tue, 14 Oct 2014 14:53:11 -0400
- Subject: Re: [PATCH V2 3/9] New commands `enable probe' and `disable probe'.
- Authentication-results: sourceware.org; auth=none
- References: <1412961772-16249-1-git-send-email-jose dot marchesi at oracle dot com> <1412961772-16249-4-git-send-email-jose dot marchesi at oracle dot com>
Hi Jose,
Thanks for the v2! Looks great. Just a minor nit.
On Friday, October 10 2014, Jose E. Marchesi wrote:
> diff --git a/gdb/probe.c b/gdb/probe.c
> index 69ca0aa..c548b27 100644
> --- a/gdb/probe.c
> +++ b/gdb/probe.c
> @@ -527,6 +527,24 @@ exists_probe_with_pops (VEC (bound_probe_s) *probes,
> return 0;
> }
>
> +/* Helper function that parses a probe linespec of the form [PROVIDER
> + [PROBE [OBJNAME]]] from the provided string STR. */
> +
> +static void
> +parse_probe_linespec (const char *str, char **provider,
> + char **probe_name, char **objname)
> +{
> + *probe_name = *objname = NULL;
> +
> + *provider = extract_arg_const (&str);
> + if (*provider)
Ops, another implicit comparison :-).
> + {
> + *probe_name = extract_arg_const (&str);
> + if (*probe_name)
Here too.
> + *objname = extract_arg_const (&str);
> + }
> +}
> +
Looks good to me otherwise.
--
Sergio
GPG key ID: 0x65FC5E36
Please send encrypted e-mail if possible
http://sergiodj.net/