# HG changeset patch # User arpi # Date 1022780698 0 # Node ID 9c8c3b5e6658964010dc59243c0755c908187dec # Parent 34b3bdd52d01e91de8495977be204952bbadc47e possible sig11 fixed in .rt parser (weisskreuzova.zip) diff -r 34b3bdd52d01 -r 9c8c3b5e6658 subreader.c --- a/subreader.c Thu May 30 14:45:13 2002 +0000 +++ b/subreader.c Thu May 30 17:44:58 2002 +0000 @@ -149,6 +149,8 @@ int len=0; char *p=source; +// printf("src=%p dest=%p \n",source,dest); + while ( !eol(*p) && *p!= '|' ) { p++,len++; } @@ -358,11 +360,14 @@ current->end = b1*360000+b2*6000+b3*100+b4/10; p=line; p+=plen;i=0; // TODO: I don't know what kind of convention is here for marking multiline subs, maybe
like in xml? - next = strstr(line,"")+8;i=0; - while ((next =sub_readtext (next, &(current->text[i])))) { + next = strstr(line,""); + if(next && strlen(next)>8){ + next+=8;i=0; + while ((next =sub_readtext (next, &(current->text[i])))) { if (current->text[i]==ERR) {return ERR;} i++; if (i>=SUB_MAX_TEXT) { printf ("Too many lines in a subtitle\n");current->lines=i;return current;} + } } current->lines=i+1; }