From: Derrick Stolee <stolee@gmail.com>
To: "Carlo Marcelo Arenas Belón" <carenas@gmail.com>, git@vger.kernel.org
Cc: dstolee@microsoft.com
Subject: Re: [PATCH] multi-pack-index: avoid dead store for struct progress
Date: Thu, 18 Oct 2018 15:36:03 -0400 [thread overview]
Message-ID: <16e462a7-cdd6-9d5d-d740-d5241485787b@gmail.com> (raw)
In-Reply-To: <20181018185920.22975-1-carenas@gmail.com>
On 10/18/2018 2:59 PM, Carlo Marcelo Arenas Belón wrote:
> it is initialized unconditionally by a call to start_progress
> below.
>
> Signed-off-by: Carlo Marcelo Arenas Belón <carenas@gmail.com>
> ---
> midx.c | 2 +-
> 1 file changed, 1 insertion(+), 1 deletion(-)
>
> diff --git a/midx.c b/midx.c
> index ea2f3ffe2e..4fac0cd08a 100644
> --- a/midx.c
> +++ b/midx.c
> @@ -941,7 +941,7 @@ static void midx_report(const char *fmt, ...)
> int verify_midx_file(const char *object_dir)
> {
> uint32_t i;
> - struct progress *progress = NULL;
> + struct progress *progress;
> struct multi_pack_index *m = load_multi_pack_index(object_dir, 1);
> verify_midx_error = 0;
>
This makes sense as a cleanup. Is there a tool that reports a wasted
initialization that you used to find this?
-Stolee
next prev parent reply other threads:[~2018-10-18 19:36 UTC|newest]
Thread overview: 4+ messages / expand[flat|nested] mbox.gz Atom feed top
2018-10-18 18:59 [PATCH] multi-pack-index: avoid dead store for struct progress Carlo Marcelo Arenas Belón
2018-10-18 19:36 ` Derrick Stolee [this message]
2018-10-18 19:56 ` Carlo Arenas
2018-10-19 2:26 ` 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=16e462a7-cdd6-9d5d-d740-d5241485787b@gmail.com \
--to=stolee@gmail.com \
--cc=carenas@gmail.com \
--cc=dstolee@microsoft.com \
--cc=git@vger.kernel.org \
/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).