From: Abhishek Agarwal <agab0323@gmail.com>
To: Junio C Hamano <gitster@pobox.com>
Cc: git@vger.kernel.org, Usman Akinyemi <usmanakinyemi202@gmail.com>,
Victoria Dye <vdye@github.com>,
Meet Soni <meetsoni3017@gmail.com>
Subject: Re: [PATCH] for-each-ref: avoid segfault on --no-format
Date: Sat, 14 Nov 2026 10:23:58 +0530 [thread overview]
Message-ID: <20261114045358.26780-1-agab0323@gmail.com> (raw)
In-Reply-To: <xmqqse148gyf.fsf@gitster.g>
Junio C Hamano <gitster@pobox.com> writes:
> The implementation of "git branch" side is quite clean; if
> format.format has a value, use it, or fill it with default. Perhaps
> mimicking it would give us the right behaviour? I didn't check.
Yes, the patch does the same thing. After parse_options() it has
if (!format.format)
format.format = "%(objectname) %(objecttype)\t%(refname)";
so "--no-format" gives the default output, like it does for "git
branch" and "git tag". The new test checks that "--format=<fmt>
--no-format" prints the same as giving no option at all.
I will send a v2 with the name in the sign-off fixed. I do not plan
any code change, unless u see something else.
Thanks.
prev parent reply other threads:[~2026-11-14 4:54 UTC|newest]
Thread overview: 4+ messages / expand[flat|nested] mbox.gz Atom feed top
2026-11-13 16:14 [PATCH] for-each-ref: avoid segfault on --no-format aeron-gh
2026-11-13 22:10 ` Junio C Hamano
2026-11-13 23:11 ` Junio C Hamano
2026-11-14 4:53 ` Abhishek Agarwal [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=20261114045358.26780-1-agab0323@gmail.com \
--to=agab0323@gmail.com \
--cc=git@vger.kernel.org \
--cc=gitster@pobox.com \
--cc=meetsoni3017@gmail.com \
--cc=usmanakinyemi202@gmail.com \
--cc=vdye@github.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