From 27b88a09c5319deb62221b8cd0ecc14cd1136e4a Mon Sep 17 00:00:00 2001 From: reimar Date: Thu, 19 May 2011 09:11:56 +0000 Subject: subreader: SAMI subs: wrap line if needed Start a new line if there's no space left to append to the previous one. git-svn-id: svn://svn.mplayerhq.hu/mplayer/trunk@33471 b3059339-0415-0410-9bf9-f77b7e298cf2 --- sub/subreader.c | 2 ++ 1 file changed, 2 insertions(+) (limited to 'sub') diff --git a/sub/subreader.c b/sub/subreader.c index 6acecb5c54..a1d2974af4 100644 --- a/sub/subreader.c +++ b/sub/subreader.c @@ -177,6 +177,8 @@ static subtitle *sub_read_line_sami(stream_t* st, subtitle *current, break; case 3: /* get all text until '<' appears */ + if (p - text >= LINE_LEN) + sami_add_line(current, text, &p); if (*s == '\0') break; else if (!strncasecmp (s, "
", 4)) { sami_add_line(current, text, &p); -- cgit v1.2.3