[vlc-devel] [PATCH] direct3d11: give enough room for the \0 in the string
Rémi Denis-Courmont
remi at remlab.net
Mon Mar 23 10:49:32 CET 2015
Le 2015-03-23 12:28, Steve Lhomme a écrit :
> ---
> modules/video_output/msw/direct3d11.c | 4 ++--
> 1 file changed, 2 insertions(+), 2 deletions(-)
>
> diff --git a/modules/video_output/msw/direct3d11.c
> b/modules/video_output/msw/direct3d11.c
> index c486071..2ff5d0d 100644
> --- a/modules/video_output/msw/direct3d11.c
> +++ b/modules/video_output/msw/direct3d11.c
> @@ -284,8 +284,8 @@ static HINSTANCE
> Direct3D11LoadShaderLibrary(void)
> HINSTANCE instance = NULL;
> /* d3dcompiler_47 is the latest on windows 8.1 */
> for (int i = 47; i > 41; --i) {
> - TCHAR filename[18];
> - _sntprintf(filename, 18, TEXT("D3DCOMPILER_%d.dll"), i);
> + TCHAR filename[19];
> + _sntprintf(filename, 19, TEXT("D3DCOMPILER_%d.dll"), i);
> instance = LoadLibrary(filename);
> if (instance) break;
> }
LGTM
--
Rémi Denis-Courmont
More information about the vlc-devel
mailing list