summaryrefslogtreecommitdiffstats
path: root/libhb/encxvid.c
diff options
context:
space:
mode:
Diffstat (limited to 'libhb/encxvid.c')
-rw-r--r--libhb/encxvid.c7
1 files changed, 7 insertions, 0 deletions
diff --git a/libhb/encxvid.c b/libhb/encxvid.c
index 6d869ae36..fbaa5a135 100644
--- a/libhb/encxvid.c
+++ b/libhb/encxvid.c
@@ -149,6 +149,13 @@ int encxvidWork( hb_work_object_t * w, hb_buffer_t ** buf_in,
xvid_enc_frame_t frame;
hb_buffer_t * in = *buf_in, * buf;
+ /* If this is the last empty frame, we're done */
+ if(!in->data)
+ {
+ *buf_out = NULL;
+ return HB_WORK_DONE;
+ }
+
/* Should be way too large */
buf = hb_buffer_init( 3 * job->width * job->height / 2 );
buf->start = in->start;