From 50e6acde52c7eaa3afa239bc14f08eced3787bd9 Mon Sep 17 00:00:00 2001 From: Carl Hetherington Date: Mon, 8 Jul 2013 23:10:01 +0100 Subject: Somewhat hacky fix to crashes in A/B with some filters. --- src/lib/combiner.cc | 8 ++++++++ 1 file changed, 8 insertions(+) (limited to 'src') diff --git a/src/lib/combiner.cc b/src/lib/combiner.cc index 367cefa7f..f7d634832 100644 --- a/src/lib/combiner.cc +++ b/src/lib/combiner.cc @@ -45,6 +45,14 @@ Combiner::process_video (shared_ptr image, bool, shared_ptr image, bool, shared_ptr sub, double t) { + if (!_image) { + /* It's possible for filters in the A-side to mean that we get a B frame + before any A; just skip the B frame in that case. This at least prevents + a crash, but may not be right. + */ + return; + } + /* Copy the right half of this image into our _image */ /* XXX: this should probably be in the Image class */ for (int i = 0; i < image->components(); ++i) { -- cgit v1.2.3