search: fix use after free
Found by: Coverity scan. CID: 96715
This commit is contained in:
parent
72ccf92c39
commit
0fb886cde9
1 changed files with 1 additions and 1 deletions
|
@ -210,10 +210,10 @@ try (struct search_ctx *ctx)
|
|||
/* Cache entry was outdated. Remove it. */
|
||||
if (!ctx->count)
|
||||
{
|
||||
*prev = cache_ent->next;
|
||||
grub_free (cache_ent->key);
|
||||
grub_free (cache_ent->value);
|
||||
grub_free (cache_ent);
|
||||
*prev = cache_ent->next;
|
||||
}
|
||||
}
|
||||
|
||||
|
|
Loading…
Reference in a new issue