mirror of
https://github.com/mpv-player/mpv
synced 2025-02-01 04:31:39 +00:00
av_sub: Set size correctly for decoded text subs
git-svn-id: svn://svn.mplayerhq.hu/mplayer/trunk@31708 b3059339-0415-0410-9bf9-f77b7e298cf2
This commit is contained in:
parent
15575403e5
commit
45d5565493
2
av_sub.c
2
av_sub.c
@ -102,10 +102,12 @@ int decode_avsub(struct sh_sub *sh, uint8_t **data, int *size, double *pts, doub
|
||||
break;
|
||||
case SUBTITLE_TEXT:
|
||||
*data = strdup(sub.rects[0]->text);
|
||||
*size = strlen(*data);
|
||||
new_type = 't';
|
||||
break;
|
||||
case SUBTITLE_ASS:
|
||||
*data = strdup(sub.rects[0]->ass);
|
||||
*size = strlen(*data);
|
||||
new_type = 'a';
|
||||
break;
|
||||
}
|
||||
|
Loading…
Reference in New Issue
Block a user