1
0
Fork 0
mirror of https://github.com/git/git.git synced 2024-04-27 07:05:08 +02:00

alloc: make allocate_alloc_state and clear_alloc_state more consistent

Since both functions are using the same data type, they should either both
refer to it as void *, or both use the real type (struct alloc_state *).
Opt for the latter.

Reviewed-by: Jonathan Nieder <jrnieder@gmail.com>
Signed-off-by: Elijah Newren <newren@gmail.com>
Signed-off-by: Junio C Hamano <gitster@pobox.com>
This commit is contained in:
Elijah Newren 2018-08-15 10:54:06 -07:00 committed by Junio C Hamano
parent ef3ca95475
commit 1731310745
2 changed files with 2 additions and 2 deletions

View File

@ -36,7 +36,7 @@ struct alloc_state {
int slab_nr, slab_alloc;
};
void *allocate_alloc_state(void)
struct alloc_state *allocate_alloc_state(void)
{
return xcalloc(1, sizeof(struct alloc_state));
}

View File

@ -15,7 +15,7 @@ void *alloc_object_node(struct repository *r);
void alloc_report(struct repository *r);
unsigned int alloc_commit_index(struct repository *r);
void *allocate_alloc_state(void);
struct alloc_state *allocate_alloc_state(void);
void clear_alloc_state(struct alloc_state *s);
#endif