]> granicus.if.org Git - handbrake/commitdiff
libhb: set HB_ERROR_CANCELED status for canceled encodes
authorJohn Stebbins <jstebbins.hb@gmail.com>
Wed, 26 Oct 2016 21:55:52 +0000 (14:55 -0700)
committerJohn Stebbins <jstebbins.hb@gmail.com>
Wed, 26 Oct 2016 21:55:52 +0000 (14:55 -0700)
This status can be queried with hb_get_state() after an encode finishes.

libhb/hb.c

index 76325555db6a42dd667cbbbf8006a3fa2e5b843e..f004a502be610125ae58ba8815b417c5d9e8d062 100644 (file)
@@ -1699,7 +1699,8 @@ void hb_resume( hb_handle_t * h )
  */
 void hb_stop( hb_handle_t * h )
 {
-    h->work_die = 1;
+    h->work_error = HB_ERROR_CANCELED;
+    h->work_die   = 1;
     hb_resume( h );
 }