From: Abhishek Agarwal Date: Sat, 14 Nov 2026 04:53:58 GMT Subject: Re: [PATCH] for-each-ref: avoid segfault on --no-format Message-ID: <20261114045358.26780-1-agab0323@gmail.com> In-Reply-To: Junio C Hamano 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= --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.