ucm: fix bad frees in get_list0 and get_list20

Signed-off-by: Alex Henrie <alexhenrie24@gmail.com>
Signed-off-by: Takashi Iwai <tiwai@suse.de>
This commit is contained in:
Alex Henrie 2020-12-26 14:35:40 -07:00 committed by Takashi Iwai
parent 5275d170e0
commit 0f4821ec17

View file

@ -666,7 +666,7 @@ static int get_list0(struct list_head *list,
}
return cnt;
__fail:
snd_use_case_free_list((const char **)res, cnt);
snd_use_case_free_list(*result, cnt);
return -ENOMEM;
}
@ -724,7 +724,7 @@ static int get_list20(struct list_head *list,
}
return cnt;
__fail:
snd_use_case_free_list((const char **)res, cnt);
snd_use_case_free_list(*result, cnt);
return -ENOMEM;
}