remote.c run-length encoding patch
Andrew Cagney
ac131313@cygnus.com
Fri Aug 20 18:41:00 GMT 1999
"J.T. Conklin" wrote:
>
> The Cisco remote protocol varient (notice that I didn't say mutant
> remote protocol this time :-) uses two hex characters instead of a
> ASCII encoding for the run length but is otherwise the same as the
> standard protocol.
>
> However, the code implementing the decoding is quite different for the
> two encodings. The standard encoding is expanded as the packet is
> read, while the Cisco varient reads the entire packet and then expands
> it in place (actually it expands it to another buffer, and the copies
> that buffer into the first). Unlike the code implementing the
> standard encoding, the Cisco varient does not detect a packet that
> would expand to larger than the buffer size, which could lead to
> corruption within GDB.
I've an alternate patch to this laying around here :-)
> In this patch, I decided to handle both encodings in the same manner.
>
> --jtc
Thanks. Michael, can you confirm that the change works on a cisco
target?
Andrew
More information about the Gdb-patches
mailing list