vlc | branch: master | Hannes Domani <ssb...@yahoo.de> | Mon Sep 15 16:50:36 2014 +0200| [59c8ec8a549dbd9b626128024d16fb2017683ff0] | committer: Jean-Baptiste Kempf
zvbi: return actual last visible row Currently in most cases the row after the last is returned. When the last row is visible vbi_draw_vt_page_region() could crash, because it went over the size of p_page.text and use invalid values (>=40) as index for p_page.color_map. Signed-off-by: Jean-Baptiste Kempf <j...@videolan.org> > http://git.videolan.org/gitweb.cgi/vlc.git/?a=commit;h=59c8ec8a549dbd9b626128024d16fb2017683ff0 --- modules/codec/zvbi.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/modules/codec/zvbi.c b/modules/codec/zvbi.c index 209c64f..a30d0bd 100644 --- a/modules/codec/zvbi.c +++ b/modules/codec/zvbi.c @@ -605,7 +605,7 @@ static int get_last_visible_row( vbi_char *p_text, int rows, int columns) { if (p_text[i].opacity != VBI_TRANSPARENT_SPACE) { - return ( i + columns - 1) / columns; + return i / columns; } } _______________________________________________ vlc-commits mailing list vlc-commits@videolan.org https://mailman.videolan.org/listinfo/vlc-commits