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