Correctly report exceptions thrown by the thumb encoder.
authorCarl Hetherington <cth@carlh.net>
Sun, 21 Oct 2012 16:20:25 +0000 (17:20 +0100)
committerCarl Hetherington <cth@carlh.net>
Sun, 21 Oct 2012 16:20:25 +0000 (17:20 +0100)
src/lib/examine_content_job.cc

index 40665e1e89eed2696b6c365d019f39d7f8fdd3f1..cad560908c63ffb66c0c5799f894b7fcc515c7dd 100644 (file)
@@ -85,8 +85,6 @@ ExamineContentJob::run ()
                shared_ptr<ImageMagickEncoder> e (new ImageMagickEncoder (fs, o, _log));
                Transcoder w (fs, o, this, _log, e);
                w.go ();
-               set_progress (1);
-               set_state (FINISHED_OK);
                
        } catch (std::exception& e) {
 
@@ -94,6 +92,7 @@ ExamineContentJob::run ()
                set_progress (1);
                set_error (e.what ());
                set_state (FINISHED_ERROR);
+               return;
                
        }