diff options
author | Ævar Arnfjörð Bjarmason <avarab@gmail.com> | 2021-09-27 14:58:42 +0200 |
---|---|---|
committer | Junio C Hamano <gitster@pobox.com> | 2021-09-27 15:02:32 -0700 |
commit | 4eb2bfdc92139f04619be21a354c025747e7ceea (patch) | |
tree | 1d7da54e9e512d6c444b9706ea95e2a184686899 /builtin/update-server-info.c | |
parent | daemon.c: refactor hostinfo_init() to HOSTINFO_INIT macro (diff) | |
download | tgif-4eb2bfdc92139f04619be21a354c025747e7ceea.tar.xz |
builtin/blame.c: refactor commit_info_init() to COMMIT_INFO_INIT macro
Remove the commit_info_init() function addded in ea02ffa3857 (mailmap:
simplify map_user() interface, 2013-01-05) and instead initialize the
"struct commit_info" with a macro.
This is the more idiomatic pattern in the codebase, and doesn't leave
us wondering when we see the *_init() function if this struct needs
more complex initialization than a macro can provide.
The get_commit_info() function is only called by the three callers
being changed here immediately after initializing the struct with the
macros, so by moving the initialization to the callers we don't need
to do it in get_commit_info() anymore.
Signed-off-by: Ævar Arnfjörð Bjarmason <avarab@gmail.com>
Signed-off-by: Junio C Hamano <gitster@pobox.com>
Diffstat (limited to 'builtin/update-server-info.c')
0 files changed, 0 insertions, 0 deletions