diff --git a/ChangeLog b/ChangeLog index 39e6a4f16..0779d7c8f 100644 --- a/ChangeLog +++ b/ChangeLog @@ -1,3 +1,8 @@ +2010-08-28 Vladimir Serbinenko + + * grub-core/normal/completion.c (grub_normal_do_completion): Free argv + on failure. + 2010-08-28 Vladimir Serbinenko * grub-core/normal/cmdline.c (grub_cmdline_get): Free cl_terms on diff --git a/grub-core/normal/completion.c b/grub-core/normal/completion.c index 40a645fb4..d127f9baf 100644 --- a/grub-core/normal/completion.c +++ b/grub-core/normal/completion.c @@ -499,7 +499,10 @@ grub_normal_do_completion (char *buf, int *restore, fail: if (argc != 0) - grub_free (argv[0]); + { + grub_free (argv); + grub_free (argv[0]); + } grub_free (match); grub_errno = GRUB_ERR_NONE;