diff options
Diffstat (limited to 'libhb/platform/macosx/encca_aac.c')
-rw-r--r-- | libhb/platform/macosx/encca_aac.c | 10 |
1 files changed, 5 insertions, 5 deletions
diff --git a/libhb/platform/macosx/encca_aac.c b/libhb/platform/macosx/encca_aac.c index e199f3640..96ee1f04d 100644 --- a/libhb/platform/macosx/encca_aac.c +++ b/libhb/platform/macosx/encca_aac.c @@ -503,19 +503,19 @@ int encCoreAudioWork(hb_work_object_t *w, hb_buffer_t **buf_in, hb_buffer_t **buf_out) { hb_work_private_t *pv = w->private_data; + hb_buffer_t * in = *buf_in; hb_buffer_t *buf; - if ((*buf_in)->size <= 0) + *buf_in = NULL; + if (in->s.flags & HB_BUF_FLAG_EOF) { // EOF on input. Finish encoding what we have buffered then send // it & the eof downstream. - *buf_out = Flush(w, *buf_in); - *buf_in = NULL; + *buf_out = Flush(w, in); return HB_WORK_DONE; } - hb_list_add(pv->list, *buf_in); - *buf_in = NULL; + hb_list_add(pv->list, in); *buf_out = buf = Encode(w); |