mirror of
https://github.com/mpv-player/mpv
synced 2024-12-18 21:06:00 +00:00
sub: fix undefined behavior with dvd://
The string could get reallocated. CC: @mpv-player/stable
This commit is contained in:
parent
6eb955e274
commit
88225d0afb
@ -189,7 +189,7 @@ static void set_dvdsub_fake_extradata(struct dec_sub *dec_sub, struct stream *st
|
||||
color = (c[2] << 16) | (c[1] << 8) | c[0];
|
||||
|
||||
if (i != 0)
|
||||
talloc_asprintf_append(s, ", ");
|
||||
s = talloc_asprintf_append(s, ", ");
|
||||
s = talloc_asprintf_append(s, "%06x", color);
|
||||
}
|
||||
s = talloc_asprintf_append(s, "\n");
|
||||
|
Loading…
Reference in New Issue
Block a user