Commit 623bd7d
submodule--helper: fix a leak in module_add()
Fix a leak in module_path(), since a6226fd (submodule--helper:
convert the bulk of cmd_add() to C, 2021-08-10), we've been freeing
add_data.sm_path, but in this case we clobbered it, and didn't free
the value we clobbered.
This makes test 28 of "t/t7400-submodule-basic.sh" ("submodule add in
subdirectory") pass when we're compiled with SANITIZE=leak..
Signed-off-by: Ævar Arnfjörð Bjarmason <[email protected]>
Reviewed-by: Glen Choo <[email protected]>
Signed-off-by: Junio C Hamano <[email protected]>1 parent 4e83605 commit 623bd7d
1 file changed
+6
-2
lines changed| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
3314 | 3314 | | |
3315 | 3315 | | |
3316 | 3316 | | |
3317 | | - | |
3318 | | - | |
| 3317 | + | |
| 3318 | + | |
| 3319 | + | |
| 3320 | + | |
| 3321 | + | |
| 3322 | + | |
3319 | 3323 | | |
3320 | 3324 | | |
3321 | 3325 | | |
| |||
0 commit comments