зеркало из https://github.com/microsoft/git.git
Fix read_mailmap to handle a caller uninterested in repo abbreviation
The only such a caller builtin-blame.c would pass NULL as the place where to store the abbreviation. Signed-off-by: Alex Riesen <raa.lkml@gmail.com> Signed-off-by: Junio C Hamano <junkio@cox.net>
This commit is contained in:
Родитель
600682aaa1
Коммит
8503ee4394
|
@ -17,6 +17,9 @@ int read_mailmap(struct path_list *map, const char *filename, char **repo_abbrev
|
|||
int abblen = sizeof(abbrev) - 1;
|
||||
int len = strlen(buffer);
|
||||
|
||||
if (!repo_abbrev)
|
||||
continue;
|
||||
|
||||
if (len && buffer[len - 1] == '\n')
|
||||
buffer[--len] = 0;
|
||||
if (!strncmp(buffer, abbrev, abblen)) {
|
||||
|
|
Загрузка…
Ссылка в новой задаче