[PATCH] sxs: Fix off by 1 error when allocating memory.
3 Oct
2020
3 Oct
'20
2:57 a.m.
Signed-off-by: Dmitry Timoshkov <dmitry(a)baikal.ru> --- dlls/sxs/cache.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/dlls/sxs/cache.c b/dlls/sxs/cache.c index bb203f50c0..0acf012032 100644 --- a/dlls/sxs/cache.c +++ b/dlls/sxs/cache.c @@ -129,7 +129,7 @@ static WCHAR *build_dll_path( const WCHAR *arch, const WCHAR *name, const WCHAR unsigned int len; if (!(path = build_assembly_name( arch, name, token, version, &len ))) return NULL; - len += build_sxs_path( sxsdir ) + 1; + len += build_sxs_path( sxsdir ) + 2; if (!(ret = HeapAlloc( GetProcessHeap(), 0, len * sizeof(WCHAR) ))) { HeapFree( GetProcessHeap(), 0, path ); -- 2.26.2
1897
Age (days ago)
1897
Last active (days ago)
1 comments
1 participants
participants (1)
-
Dmitry Timoshkov