[MPlayer-cvslog] r35795 - in trunk/libass: ass.c ass_parse.c ass_render.c

SubJunk subversion at mplayerhq.hu
Sat Jan 19 22:47:31 CET 2013


Author: SubJunk
Date: Sat Jan 19 22:47:31 2013
New Revision: 35795

Log:
Updated libass to 7e45532

- Removes a redundant warning message
- Fixes a wrong condition
- Fixes a leak when an error occurs

Modified:
   trunk/libass/ass.c
   trunk/libass/ass_parse.c
   trunk/libass/ass_render.c

Modified: trunk/libass/ass.c
==============================================================================
--- trunk/libass/ass.c	Sat Jan 19 14:00:41 2013	(r35794)
+++ trunk/libass/ass.c	Sat Jan 19 22:47:31 2013	(r35795)
@@ -988,7 +988,9 @@ static char *sub_recode(ASS_Library *lib
                     oleft += size;
                 } else {
                     ass_msg(library, MSGL_WARN, "Error recoding file");
-                    return NULL;
+                    free(outbuf);
+		    outbuf = NULL;
+		    goto out;
                 }
             } else if (clear)
                 break;
@@ -996,6 +998,7 @@ static char *sub_recode(ASS_Library *lib
         outbuf[osize - oleft - 1] = 0;
     }
 
+out:
     if (icdsc != (iconv_t) (-1)) {
         (void) iconv_close(icdsc);
         icdsc = (iconv_t) (-1);

Modified: trunk/libass/ass_parse.c
==============================================================================
--- trunk/libass/ass_parse.c	Sat Jan 19 14:00:41 2013	(r35794)
+++ trunk/libass/ass_parse.c	Sat Jan 19 22:47:31 2013	(r35795)
@@ -241,7 +241,7 @@ static char *parse_vector_clip(ASS_Rende
     drawing->scale = scale;
     drawing->scale_x = render_priv->font_scale_x * render_priv->font_scale;
     drawing->scale_y = render_priv->font_scale;
-    while (*p != ')' && *p != '}' && p != 0)
+    while (*p != ')' && *p != '}' && *p != 0)
         ass_drawing_add_char(drawing, *p++);
     skipopt(')');
 

Modified: trunk/libass/ass_render.c
==============================================================================
--- trunk/libass/ass_render.c	Sat Jan 19 14:00:41 2013	(r35794)
+++ trunk/libass/ass_render.c	Sat Jan 19 22:47:31 2013	(r35795)
@@ -546,7 +546,6 @@ static void blend_vector_clip(ASS_Render
     ASS_Drawing *drawing = render_priv->state.clip_drawing;
     BitmapHashKey key;
     BitmapHashValue *val;
-    int error;
 
     if (!drawing)
         return;
@@ -586,10 +585,6 @@ static void blend_vector_clip(ASS_Render
 
         clip_bm = outline_to_bitmap(render_priv->library,
                 render_priv->ftlibrary, outline, 0);
-        if (clip_bm == NULL) {
-            ass_msg(render_priv->library, MSGL_WARN,
-                "Clip vector rasterization failed: %d. Skipping.", error);
-        }
 
         // Add to cache
         memset(&v, 0, sizeof(v));


More information about the MPlayer-cvslog mailing list