]> git.sesse.net Git - vlc/commitdiff
freetype: simplify
authorPierre Ynard <linkfanel@yahoo.fr>
Wed, 16 Sep 2009 10:33:43 +0000 (12:33 +0200)
committerPierre Ynard <linkfanel@yahoo.fr>
Wed, 16 Sep 2009 10:33:43 +0000 (12:33 +0200)
modules/misc/freetype.c

index c5d291d629c3e126e2346ea1ac544c4e0a90bb45..b00a50cc4a6b5ac639eecd7eb70e875b8d2464be 100644 (file)
@@ -323,11 +323,10 @@ static int Create( vlc_object_t *p_this )
     fontindex=0;
     if( !psz_fontfamily || !*psz_fontfamily )
     {
+        free( psz_fontfamily );
 #ifdef HAVE_FONTCONFIG
-        free( psz_fontfamily);
         psz_fontfamily=strdup( DEFAULT_FONT );
 #else
-        free( psz_fontfamily );
         psz_fontfamily = (char *)malloc( PATH_MAX + 1 );
         if( !psz_fontfamily )
             goto error;