changeset 21581:37c795807a1d

Another simplification
author reimar
date Mon, 11 Dec 2006 22:32:13 +0000
parents 8a710a7b68ea
children 239f2c145b2f
files libvo/sub.c
diffstat 1 files changed, 1 insertions(+), 3 deletions(-) [+]
line wrap: on
line diff
--- a/libvo/sub.c	Mon Dec 11 22:29:08 2006 +0000
+++ b/libvo/sub.c	Mon Dec 11 22:32:13 2006 +0000
@@ -383,7 +383,6 @@
 inline static void vo_update_text_sub(mp_osd_obj_t* obj,int dxs,int dys){
    unsigned char *t;
    int c,i,j,l,x,y,font,prevc,counter;
-   int len;
    int k;
    int lastStripPosition;
    int xsize;
@@ -417,9 +416,8 @@
 	    xsize = -vo_font->charspace;
 	  l--;
 	  t=vo_sub->text[i++];	  
-	  len=strlen(t)-1;
 	    char_position = 0;
-	    char_seq = (int *) malloc((len + 1) * sizeof(int));
+	    char_seq = calloc(strlen(t), sizeof(int));
 
 	  prevc = -1;