[MPlayer-cvslog] r32643 - trunk/libass/ass_drawing.c
komh
subversion at mplayerhq.hu
Tue Nov 23 15:44:27 CET 2010
Author: komh
Date: Tue Nov 23 15:44:26 2010
New Revision: 32643
Log:
Check the validity of an argument, font.
If failing to open a font file when using -ass, it becomes NULL and causes
MPlayer to be crashed.
Modified:
trunk/libass/ass_drawing.c
Modified: trunk/libass/ass_drawing.c
==============================================================================
--- trunk/libass/ass_drawing.c Sun Nov 21 20:46:37 2010 (r32642)
+++ trunk/libass/ass_drawing.c Tue Nov 23 15:44:26 2010 (r32643)
@@ -367,7 +367,7 @@ ASS_Drawing *ass_drawing_new(void *fontc
drawing->fontconfig_priv = fontconfig_priv;
drawing->font = font;
drawing->ftlibrary = lib;
- drawing->library = font->library;
+ drawing->library = font ? font->library : NULL;
drawing->scale_x = 1.;
drawing->scale_y = 1.;
More information about the MPlayer-cvslog
mailing list