Files
git/builtin
Ævar Arnfjörð Bjarmason 486620ae0c name-rev: don't xstrdup() an already dup'd string
When "add_to_tip_table()" is called with a non-zero
"shorten_unambiguous" we always return an xstrdup()'d string, which
we'd then xstrdup() again, leaking memory. See [1] and [2] for how
this leak came about.

We could xstrdup() only if "shorten_unambiguous" wasn't true, but
let's instead inline this code, so that information on whether we need
to xstrdup() is contained within add_to_tip_table().

1. 98c5c4ad01 (name-rev: allow to specify a subpath for --refs
   option, 2013-06-18)
2. b23e0b9353 (name-rev: allow converting the exact object name at
   the tip of a ref, 2013-07-07)

Signed-off-by: Ævar Arnfjörð Bjarmason <avarab@gmail.com>
Signed-off-by: Junio C Hamano <gitster@pobox.com>
2023-02-06 15:34:37 -08:00
..
2022-12-26 11:42:05 +09:00
2023-01-21 17:21:58 -08:00
2023-01-13 14:17:14 -08:00
2023-01-05 15:07:22 +09:00
2023-01-08 10:28:34 +09:00
2023-02-06 15:34:37 -08:00
2022-12-14 15:55:46 +09:00
2022-12-14 15:55:46 +09:00
2022-11-23 11:22:24 +09:00
2023-01-23 13:39:52 -08:00
2022-11-16 14:57:32 -05:00
2022-12-14 15:55:46 +09:00
2022-12-14 15:55:46 +09:00
2022-12-18 11:48:26 +09:00