Re: [PATCH v12 4/7] send-pack: extension for client-side status report
- From
Junio C Hamano <gitster@pobox.com>
- Date
- Apr 15, 2020, 20:36 UTC
- Message-ID
- <xmqqh7xk5vwc.fsf@gitster.c.googlers.com>
- In-Reply-To
- <20200414123257.27449-5-worldhello.net@gmail.com>
Jiang Xin <worldhello.net@gmail.com> writes:
> + if (msg) > + hint->remote_status = xstrdup(msg); > + else if (extended_status) > + hint->remote_status = xstrdup(extended_status);
contrib/coccinelle/xstrdup_or_null.cocci suggests to rewrite the above like so:
if (msg) hint->remote_status = xstrdup(msg); else hint->remote_status = xstrdup_or_null(extended_status);
I'll queue a fix-up patch to keep 'pu' passing the test suite for now.