diff options
author | wm4 <wm4@nowhere> | 2014-11-04 21:08:58 +0100 |
---|---|---|
committer | wm4 <wm4@nowhere> | 2014-11-04 21:08:58 +0100 |
commit | c24292e83863d73ea1729cb946d744db5a74c7da (patch) | |
tree | af96160bd05f86eec38d8cda8f23de1c41648cc6 /libass/ass.c | |
parent | cf6dbcafd7f9e17f6f9e807c23de020d91e1c72e (diff) | |
download | libass-c24292e83863d73ea1729cb946d744db5a74c7da.tar.bz2 libass-c24292e83863d73ea1729cb946d744db5a74c7da.tar.xz |
Load embedded fonts from memory correctly
Diffstat (limited to 'libass/ass.c')
-rw-r--r-- | libass/ass.c | 13 |
1 files changed, 3 insertions, 10 deletions
diff --git a/libass/ass.c b/libass/ass.c index 892a627..63c31a6 100644 --- a/libass/ass.c +++ b/libass/ass.c @@ -776,12 +776,6 @@ static int process_line(ASS_Track *track, char *str) break; } } - - // there is no explicit end-of-font marker in ssa/ass - if ((track->parser_priv->state != PST_FONTS) - && (track->parser_priv->fontname)) - decode_font(track); - return 0; } @@ -809,6 +803,9 @@ static int process_text(ASS_Track *track, char *str) break; p = q; } + // there is no explicit end-of-font marker in ssa/ass + if (track->parser_priv->fontname) + decode_font(track); return 0; } @@ -1088,10 +1085,6 @@ static ASS_Track *parse_memory(ASS_Library *library, char *buf) for (i = 0; i < track->n_events; ++i) track->events[i].ReadOrder = i; - // there is no explicit end-of-font marker in ssa/ass - if (track->parser_priv->fontname) - decode_font(track); - if (track->track_type == TRACK_TYPE_UNKNOWN) { ass_free_track(track); return 0; |