]> git.proxmox.com Git - grub2.git/commit
kern/parser: Fix a memory leak
authorChris Coulson <chris.coulson@canonical.com>
Wed, 18 Nov 2020 00:59:24 +0000 (00:59 +0000)
committerDaniel Kiper <daniel.kiper@oracle.com>
Tue, 2 Mar 2021 14:54:19 +0000 (15:54 +0100)
commitc6c426e5ab6ea715153b72584de6bd8c82f698ec
tree2c4835e9a975976f072e0b1d13d8fb90293d0ab7
parentb911884dd707ba1e6f641eb17857df3155013a45
kern/parser: Fix a memory leak

The getline() function supplied to grub_parser_split_cmdline() returns
a newly allocated buffer and can be called multiple times, but the
returned buffer is never freed.

Signed-off-by: Chris Coulson <chris.coulson@canonical.com>
Reviewed-by: Daniel Kiper <daniel.kiper@oracle.com>
grub-core/kern/parser.c