Re: [PATCH 2/3] pkt-line: tighten sideband PACK check when tracing
- From
Jeff King <peff@peff.net>
- Date
- Jun 12, 2015, 21:41 UTC
- Message-ID
- <20150612214152.GA26217@peff.net>
- In-Reply-To
- <CAGZ79kb+DBUqAy45+Bc=MTA6HuGrj9MzyODZGTvOcP_XefAu=A@mail.gmail.com>
On Fri, Jun 12, 2015 at 02:39:01PM -0700, Stefan Beller wrote:
Show 10 quoted lines
> > - if (starts_with(buf, "PACK") || starts_with(buf + 1, "PACK")) {
> > + if (starts_with(buf, "PACK") || starts_with(buf, "\1PACK")) {
>
> This answers the question on the previous patch actually, maybe the
> code could be improved to
>
> if (is_sidechannel(out, ...)
> out++;
> if (starts_with(buf, "PACK") {
> ...If it's not a PACK, then we don't want to skip past the side-channel character (we show it as part of the trace).
Hopefully the end result after patch 3 reads well, as it sets an explicit "sideband" flag.
-Peff