submodule: fix leaking update strategy
We're not freeing the submodule update strategy command. Provide a helper function that does this for us and call it in `update_data_release()`. Signed-off-by: Patrick Steinhardt <ps@pks.im> Signed-off-by: Junio C Hamano <gitster@pobox.com>
This commit is contained in:

committed by
Junio C Hamano

parent
3aef7a05ad
commit
2e492f2047
@ -424,6 +424,11 @@ int parse_submodule_update_strategy(const char *value,
|
||||
return 0;
|
||||
}
|
||||
|
||||
void submodule_update_strategy_release(struct submodule_update_strategy *strategy)
|
||||
{
|
||||
free((char *) strategy->command);
|
||||
}
|
||||
|
||||
const char *submodule_update_type_to_string(enum submodule_update_type type)
|
||||
{
|
||||
switch (type) {
|
||||
|
Reference in New Issue
Block a user