Re: [PATCH v2 8/9] parse-options: don't leak alias help messages
- From
Andrzej Hunt <andrzej@ahunt.org>
- Date
- Mar 14, 2021, 20:00 UTC
- Message-ID
- <9429174D-660C-44B9-8EA7-C1B22ACBA45F@ahunt.org>
- In-Reply-To
- <4397c1fd80205d142fbd184c6d13fd07c4dbfa21.1615747662.git.gitgitgadget@gmail.com>
Show 5 quoted lines
> On 14 Mar 2021, at 19:47, Andrzej Hunt via GitGitGadget <gitgitgadget@gmail.com> wrote:
> + for (i = 0; options[i].type != OPTION_END; i++) {
> + if (options[i].flags & PARSE_OPT_FROM_ALIAS) {
> + free((void *)options[i].help);
> + }Oops, I did it again: I’ll remove these unnecessary braces in V3.