[PATCH] remote_rcmd

Andrew Cagney ac131313@ges.redhat.com
Sun Jul 14 09:51:00 GMT 2002


> Hi,
> 
> This small patch adds support for receving more that ~200 bytes
> of output from the "qRcmd" request (ie the monitor command).
> 
> I have no idea if this will break any stubs, but hopefully not.
> I don't know how often stubs implement the qRcmd request.
> 
> 2002-06-27  Johan Rydberg  <jrydberg@rtmk.org>
> 
>         * remote.c (remote_rcmd): Continue reading output from
>         stub until receiving OK.

If I understand this patch correctly, it is changing things so that it 
allows:

	-> rCmd <command>
	<- <HEX-OUTPUT>
	<- <HEX-OUTPUT>
	<- OK

This is wrong.  The target should send:

	-> rCmd <command>
	<- O <HEX-OUTPUT>
	<- O <HEX-OUTPUT>
	<- OK

when transfering a longer buffer.

Andrew

> Index: remote.c
> ===================================================================
> RCS file: /cvs/src/src/gdb/remote.c,v
> retrieving revision 1.87
> diff -u -u -r1.87 remote.c
> --- remote.c	15 Jun 2002 22:05:32 -0000	1.87
> +++ remote.c	27 Jun 2002 01:42:02 -0000
> @@ -5210,7 +5210,6 @@
>  	  char c = (fromhex (p[0]) << 4) + fromhex (p[1]);
>  	  fputc_unfiltered (c, outbuf);
>  	}
> -      break;
>      }
>  }
> 




More information about the Gdb-patches mailing list