diff options
| author | Carl Hetherington <cth@carlh.net> | 2017-04-04 23:15:06 +0100 |
|---|---|---|
| committer | Carl Hetherington <cth@carlh.net> | 2017-04-04 23:15:06 +0100 |
| commit | 2525b8babdfe69f81ad873f1a89d914f56174d91 (patch) | |
| tree | 6789b784fd3917c5ff03ec8b7a65acb42a358944 /src | |
| parent | 8aced08ae46f4bdb66b7a587351ff88f60f8fcc1 (diff) | |
Fix crash with a missing subtitle asset.
Diffstat (limited to 'src')
| -rw-r--r-- | src/reel.cc | 8 |
1 files changed, 5 insertions, 3 deletions
diff --git a/src/reel.cc b/src/reel.cc index b94197d0..89fc3a45 100644 --- a/src/reel.cc +++ b/src/reel.cc @@ -230,9 +230,11 @@ Reel::resolve_refs (list<shared_ptr<Asset> > assets) _main_subtitle->asset_ref().resolve (assets); /* Interop subtitle handling is all special cases */ - shared_ptr<InteropSubtitleAsset> iop = dynamic_pointer_cast<InteropSubtitleAsset> (_main_subtitle->asset_ref().asset ()); - if (iop) { - iop->resolve_fonts (assets); + if (_main_subtitle->asset_ref().resolved()) { + shared_ptr<InteropSubtitleAsset> iop = dynamic_pointer_cast<InteropSubtitleAsset> (_main_subtitle->asset_ref().asset()); + if (iop) { + iop->resolve_fonts (assets); + } } } |
