mirror of
https://github.com/git/git
synced 2024-08-27 11:39:22 +00:00
![Antoine Pelisse](/assets/img/avatar_default.png)
Simplify map_user(), mostly to avoid copies of string buffers. It also simplifies caller functions. map_user() directly receive pointers and length from the commit buffer as mail and name. If mapping of the user and mail can be done, the pointer is updated to a new location. Lengths are also updated if necessary. The caller of map_user() can then copy the new email and name if necessary. Signed-off-by: Antoine Pelisse <apelisse@gmail.com> Signed-off-by: Junio C Hamano <gitster@pobox.com>
11 lines
271 B
C
11 lines
271 B
C
#ifndef MAILMAP_H
|
|
#define MAILMAP_H
|
|
|
|
int read_mailmap(struct string_list *map, char **repo_abbrev);
|
|
void clear_mailmap(struct string_list *map);
|
|
|
|
int map_user(struct string_list *map,
|
|
const char **email, size_t *emaillen, const char **name, size_t *namelen);
|
|
|
|
#endif
|