card-mcrd: Free the allocated structures on cleanup

https://bugs.chromium.org/p/oss-fuzz/issues/detail?id=18416
This commit is contained in:
Jakub Jelen 2019-10-21 15:59:16 +02:00 committed by Frank Morgner
parent 6522df7587
commit 61cd7fcdb2
1 changed files with 1 additions and 0 deletions

View File

@ -297,6 +297,7 @@ static int mcrd_finish(sc_card_t * card)
while (priv->df_infos) {
struct df_info_s *tmp = priv->df_infos->next;
clear_special_files(priv->df_infos);
free(priv->df_infos);
priv->df_infos = tmp;
}
free(priv);