[vlc-devel] [PATCH 3/3] stream_ReadLine: properly reset text encoding parameters

Rémi Denis-Courmont remi at remlab.net
Wed Sep 30 21:06:27 CEST 2020


Le tiistaina 29. syyskuuta 2020, 15.12.02 EEST Pierre Ynard via vlc-devel a 
écrit :
> Only the iconv handle was correctly reset, potentially leading again to
> wrong or inconsistent parameters.
> 
> 
> diff --git a/src/input/stream.c b/src/input/stream.c
> index 2d9f4f9..65e1e24 100644
> --- a/src/input/stream.c
> +++ b/src/input/stream.c
> @@ -217,6 +217,8 @@ char *vlc_stream_ReadLine( stream_t *s )
>                  vlc_iconv_close( priv->text.conv );
>                  priv->text.conv = (vlc_iconv_t)-1;
>              }
> +            priv->text.char_width = 1;
> +            priv->text.little_endian = false;
> 
>              if( !memcmp( p_data, "\xFF\xFE", 2 ) )
>              {

Patches 2 and 3 LGTM

-- 
雷米‧德尼-库尔蒙
http://www.remlab.net/





More information about the vlc-devel mailing list