git.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
From: Jeff King <peff@peff.net>
To: Brandon Casey <casey@nrlssc.navy.mil>
Cc: gitster@pobox.com, git@vger.kernel.org,
	Brandon Casey <drafnel@gmail.com>
Subject: Re: [PATCH 2/2] builtin/commit.c: set status_format _after_ option parsing
Date: Thu, 26 May 2011 17:17:23 -0400	[thread overview]
Message-ID: <20110526211723.GE31340@sigill.intra.peff.net> (raw)
In-Reply-To: <vdMu20HxiNaWL_IogfamtflLupHrDNZVtQH5MK7obj8IjaOAuDtj-EwLzysKLoeGXYfBRtJqF-hgEQF5bfRzsQ@cipher.nrlssc.navy.mil>

On Thu, May 26, 2011 at 01:43:21PM -0700, Brandon Casey wrote:

> 'git status' should use --porcelain output format when -z is given.
> It was not doing so since the _effect_ of using -z, namely that
> null_termination would be set, was being checked _before_ option parsing
> was performed.
> 
> So, move the check so that it is performed after option parsing.

Wow, that's an embarrassing bug. I was about to own up to it, but it
actually looks like it is Junio's bug from 173e6c8 (git stat -s: short
status output, 2009-08-04). Of course, I _twice_ modified the
conditional afterwards and failed to notice that it was doing absolutely
nothing. So I'm not sure which one of us deserves the brown paper bag. :)

Your fix looks obviously correct.

Acked-by: Jeff King <peff@peff.net>

-Peff

  reply	other threads:[~2011-05-26 21:17 UTC|newest]

Thread overview: 7+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2011-05-26 20:43 [PATCH 1/2] t7508: demonstrate status's failure to use --porcelain format with -z Brandon Casey
2011-05-26 20:43 ` [PATCH 2/2] builtin/commit.c: set status_format _after_ option parsing Brandon Casey
2011-05-26 21:17   ` Jeff King [this message]
2011-05-26 21:34     ` Brandon Casey
2011-05-26 21:45 ` [PATCH 1/2] t7508: demonstrate status's failure to use --porcelain format with -z Junio C Hamano
2011-05-26 22:51   ` Brandon Casey
2011-05-26 23:31     ` Junio C Hamano

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=20110526211723.GE31340@sigill.intra.peff.net \
    --to=peff@peff.net \
    --cc=casey@nrlssc.navy.mil \
    --cc=drafnel@gmail.com \
    --cc=git@vger.kernel.org \
    --cc=gitster@pobox.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;
as well as URLs for NNTP newsgroup(s).