The decoder was setting the last character but forgot to increment out->size,
which led to weird artifacts being displayed when playing in e.g. VLC.
git-svn-id: svn://svn.handbrake.fr/HandBrake/trunk@5346
b64f7644-9d1e-0410-96f1-
a4d463321fa5
if ( out->size > 0 && out->data[out->size - 1] != '\0' ) {
// NOTE: out->size remains unchanged
hb_buffer_realloc( out, out->size + 1 );
- out->data[out->size] = '\0';
+ out->data[out->size++] = '\0';
}
*buf_in = NULL;