This is the mail archive of the gdb-patches@sourceware.org mailing list for the GDB project.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]
Other format: [Raw text]

Re: [RFA 3/7 take 2] New gdbserver functionality


On 05/16/2013 03:48 PM, Gary Benson wrote:

> +	  sep = strchr (annex, '=');
> +	  if (!sep)

Please write

         if (sep == NULL)

There are more instances of this in the patch.

> +	    break;
> +
> +	  len = sep - annex;
> +	  if (len == 5 && !strncmp (annex, "start", 5))

strncmp does not return a boolean.  Please write:

> +	  if (len == 5 && strncmp (annex, "start", 5) == 0)


> +	  else if (len == 4 && !strncmp (annex, "prev", 4))

Ditto.

Otherwise looks good to me too.

There should be a NEWS entry for the new RSP feature too though.

-- 
Pedro Alves


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]