crash fixed if no [fontpath] in .desc

git-svn-id: svn://svn.mplayerhq.hu/mplayer/trunk@1358 b3059339-0415-0410-9bf9-f77b7e298cf2
This commit is contained in:
arpi 2001-07-20 01:51:01 +00:00
parent a2206b10b5
commit e34af51711
1 changed files with 2 additions and 0 deletions

View File

@ -51,6 +51,8 @@ int version=0;
desc=malloc(sizeof(font_desc_t));if(!desc) return NULL; desc=malloc(sizeof(font_desc_t));if(!desc) return NULL;
memset(desc,0,sizeof(font_desc_t)); memset(desc,0,sizeof(font_desc_t));
desc->fpath="";
f=fopen(fname,"rt");if(!f){ printf("font: can't open file: %s\n",fname); return NULL;} f=fopen(fname,"rt");if(!f){ printf("font: can't open file: %s\n",fname); return NULL;}
// set up some defaults, and erase table // set up some defaults, and erase table