Commit 7117284e authored by Rémi Duraffort's avatar Rémi Duraffort

smooth: fix potential memleak

parent ddac8657
......@@ -363,13 +363,12 @@ static chunk_t *build_init_chunk( stream_t *s )
if( !ret->data )
goto build_init_chunk_error;
int res = build_smoo_box( s, ret->data );
if( res != VLC_SUCCESS )
goto build_init_chunk_error;
return ret;
if( build_smoo_box( s, ret->data ) == VLC_SUCCESS)
return ret;
free( ret->data );
build_init_chunk_error:
free( ret );
msg_Err( s, "build_init_chunk failed" );
return NULL;
}
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment