Don't try to make decoders when there is no content.
authorCarl Hetherington <cth@carlh.net>
Tue, 12 Feb 2013 19:37:05 +0000 (19:37 +0000)
committerCarl Hetherington <cth@carlh.net>
Tue, 12 Feb 2013 19:37:05 +0000 (19:37 +0000)
src/lib/decoder_factory.cc

index 59e15722d6dd0f7b652c847b325af2108249bbb6..478ccd1c18da55d155ab439270b3fa4b90a1b260 100644 (file)
@@ -39,6 +39,10 @@ decoder_factory (
        shared_ptr<Film> f, DecodeOptions o
        )
 {
+       if (f->content().empty()) {
+               return Decoders ();
+       }
+       
        if (boost::filesystem::is_directory (f->content_path()) || f->content_type() == STILL) {
                /* A single image file, or a directory of them */
                return Decoders (