lib/gterm: Free terms array when no terminals are initialized
diff --git a/common/lib/gterm.c b/common/lib/gterm.c
index 5271c434..53eb8787 100644
--- a/common/lib/gterm.c
+++ b/common/lib/gterm.c
@@ -842,6 +842,7 @@ no_load_font:;
}
if (terms_i == 0) {
+ pmm_free(terms, fbs_count * sizeof(void *));
return false;
}
