tmplayer: Don't append NULL + 1 to the string buffer when parsing lines without text
Fixes https://gitlab.freedesktop.org/gstreamer/gstreamer/-/issues/4417 Fixes CVE-2025-47808 Part-of: <https://gitlab.freedesktop.org/gstreamer/gstreamer/-/merge_requests/9132>
This commit is contained in:
parent
48bf6a92d7
commit
6b19f11751
@ -125,7 +125,9 @@ tmplayer_parse_line (ParserState * state, const gchar * line, guint line_num)
|
||||
* durations from the start times anyway, so as long as the parser just
|
||||
* forwards state->start_time by duration after it pushes the line we
|
||||
* are about to return it will all be good. */
|
||||
g_string_append (state->buf, text_start + 1);
|
||||
if (text_start) {
|
||||
g_string_append (state->buf, text_start + 1);
|
||||
}
|
||||
} else if (line_num > 0) {
|
||||
GST_WARNING ("end of subtitle unit but no valid start time?!");
|
||||
}
|
||||
|
Loading…
x
Reference in New Issue
Block a user