зеркало из https://github.com/microsoft/git.git
Merge branch 'ab/mailmap-leakfix'
Leakfix. * ab/mailmap-leakfix: mailmap.c: fix a memory leak in free_mailap_{info,entry}()
This commit is contained in:
Коммит
f0b567898b
|
@ -37,6 +37,7 @@ static void free_mailmap_info(void *p, const char *s)
|
||||||
s, debug_str(mi->name), debug_str(mi->email));
|
s, debug_str(mi->name), debug_str(mi->email));
|
||||||
free(mi->name);
|
free(mi->name);
|
||||||
free(mi->email);
|
free(mi->email);
|
||||||
|
free(mi);
|
||||||
}
|
}
|
||||||
|
|
||||||
static void free_mailmap_entry(void *p, const char *s)
|
static void free_mailmap_entry(void *p, const char *s)
|
||||||
|
@ -52,6 +53,7 @@ static void free_mailmap_entry(void *p, const char *s)
|
||||||
|
|
||||||
me->namemap.strdup_strings = 1;
|
me->namemap.strdup_strings = 1;
|
||||||
string_list_clear_func(&me->namemap, free_mailmap_info);
|
string_list_clear_func(&me->namemap, free_mailmap_info);
|
||||||
|
free(me);
|
||||||
}
|
}
|
||||||
|
|
||||||
/*
|
/*
|
||||||
|
|
Загрузка…
Ссылка в новой задаче