From: Daniel Jacobowitz <drow@false.org>
To: Nathan Sidwell <nathan@codesourcery.com>
Cc: gdb-patches@sources.redhat.com
Subject: Re: [PATCH] remote protocol cleanups
Date: Tue, 08 Mar 2005 13:37:00 -0000 [thread overview]
Message-ID: <20050308133700.GB7417@nevyn.them.org> (raw)
In-Reply-To: <422D87F3.9040804@codesourcery.com>
On Tue, Mar 08, 2005 at 11:09:39AM +0000, Nathan Sidwell wrote:
> Daniel Jacobowitz wrote:
> >On Wed, Feb 09, 2005 at 11:53:50AM +0000, Nathan Sidwell wrote:
>
> >>2) remote_write_bytes attempts to honour get_memory_write_packet_size's
> >>limit, but fails in two ways when that is a very small number. a) it can
> >>end up with a negative byte count. b) it deducts the number of chars in
> >>the *maximal* length count, not the number of chars in the actual length
> >>count. This can result in packets sending 1 or 2 bytes fewer than they
> >>are limited to.
>
> >
> >Mostly OK, but one question. I don't get the "max (todo, 1)". If no
> >bytes fit, aren't we hosed? It seems like an error condition; we
> >shouldn't be violating the size limit.
>
> It appears the minimum size setting is somewhat arbitrary, and incorrect.
> /* NOTE: 16 is just chosen at random. */
> #ifndef MIN_REMOTE_PACKET_SIZE
> #define MIN_REMOTE_PACKET_SIZE 16
> #endif
>
> the minumum packet size is actually
> 7 - strlen ("$M,:#NN")
> 8 - hexnumlen (memaddr) (32 bit host)
> 1 - hexnumlen (len)
> 2 - data
> = 18 characters
>
> This patch fixes that size calculation. ok?
Yes, this is OK.
--
Daniel Jacobowitz
CodeSourcery, LLC
prev parent reply other threads:[~2005-03-08 13:37 UTC|newest]
Thread overview: 4+ messages / expand[flat|nested] mbox.gz Atom feed top
2005-02-09 14:19 Nathan Sidwell
2005-03-07 22:45 ` Daniel Jacobowitz
2005-03-08 11:09 ` Nathan Sidwell
2005-03-08 13:37 ` Daniel Jacobowitz [this message]
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=20050308133700.GB7417@nevyn.them.org \
--to=drow@false.org \
--cc=gdb-patches@sources.redhat.com \
--cc=nathan@codesourcery.com \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox