summaryrefslogtreecommitdiffstats
path: root/libvo/font_load.c
diff options
context:
space:
mode:
Diffstat (limited to 'libvo/font_load.c')
-rw-r--r--libvo/font_load.c9
1 files changed, 9 insertions, 0 deletions
diff --git a/libvo/font_load.c b/libvo/font_load.c
index 22a9045e9b..e005f6ecac 100644
--- a/libvo/font_load.c
+++ b/libvo/font_load.c
@@ -245,10 +245,19 @@ while(fgets(sor,1020,f)){
}
}
printf("Syntax error in font desc: %s\n",sor);
+ free(desc);
+ fclose(f);
+ return NULL;
}
fclose(f);
+ if (first == 1) {
+ printf("%s is empty or a directory, ignoring\n", fname);
+ free(desc);
+ return NULL;
+ }
+
//printf("font: pos of U = %d\n",desc->start[218]);
for(i=0;i<=fontdb;i++){