From 885eb095d305198dffcb515f577a876dfd066ce4 Mon Sep 17 00:00:00 2001 From: eyck Date: Thu, 24 May 2001 09:19:38 +0000 Subject: Wrong header lenght count for vplayer format fixed. git-svn-id: svn://svn.mplayerhq.hu/mplayer/trunk@859 b3059339-0415-0410-9bf9-f77b7e298cf2 --- subreader.c | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) (limited to 'subreader.c') diff --git a/subreader.c b/subreader.c index 1a0c54cd03..667eb2eeb3 100644 --- a/subreader.c +++ b/subreader.c @@ -222,13 +222,13 @@ subtitle *sub_read_line_vplayer(FILE *fd,subtitle *current) { int a1,a2,a3,b1,b2,b3; int setime,etime; char *p=NULL, *q=NULL, *l=NULL,*next; - int i,len,len2; + int i,len,len2,plen; bzero (current, sizeof(current)); while (!current->text[0]) { if (!fgets (line, 1000, fd)) return NULL; - if ((len=sscanf (line, "%d:%d:%d:",&a1,&a2,&a3)) < 3) + if ((len=sscanf (line, "%d:%d:%d:%n",&a1,&a2,&a3,&plen)) < 3) continue; if (!fgets (line2, 1000, fd)) return NULL; if ((len2=sscanf (line2, "%d:%d:%d:",&b1,&b2,&b3)) < 3) @@ -239,7 +239,7 @@ subtitle *sub_read_line_vplayer(FILE *fd,subtitle *current) { current->start = a1*360000+a2*6000+a3*100; current->end = b1*360000+b2*6000+b3*100; // teraz czas na wkopiowanie stringu - p=line; p+=9;i=0; + p=line; p+=plen;i=0; if (*p!='|') { // next = p,i=0; -- cgit v1.2.3