]> git.ipfire.org Git - thirdparty/git.git/commit
mailmap: fix check-mailmap with full mailmap line
authorJacob Keller <jacob.keller@gmail.com>
Fri, 21 Feb 2025 23:47:58 +0000 (15:47 -0800)
committerJunio C Hamano <gitster@pobox.com>
Sat, 22 Feb 2025 02:27:16 +0000 (18:27 -0800)
commitbb60c5213134cda73c31940ec0fb33c361a064eb
treeee904f2746cf68a692306a19b6f88966c325f0a1
parente1fbebe347426ef7974dc2198f8a277b7c31c8fe
mailmap: fix check-mailmap with full mailmap line

I recently had reported to me a crash from a coworker using the recently
added sendemail mailmap support:

  3724814 Segmentation fault      (core dumped) git check-mailmap "bugs@company.xx"

This appears to happen because of the NULL pointer name passed into
map_user(). Fix this by passing "" instead of NULL so that we have a
valid pointer.

Signed-off-by: Jacob Keller <jacob.keller@gmail.com>
Signed-off-by: Junio C Hamano <gitster@pobox.com>
builtin/check-mailmap.c
t/t4203-mailmap.sh