Huw Davies : netapi32: Return the length in characters not bytes.
Module: wine Branch: master Commit: 8a02f6dd0af647c4c804f0bbb0e768d994072ce6 URL: https://source.winehq.org/git/wine.git/?a=commit;h=8a02f6dd0af647c4c804f0bbb... Author: Huw Davies <huw(a)codeweavers.com> Date: Thu Dec 2 07:46:17 2021 +0000 netapi32: Return the length in characters not bytes. Signed-off-by: Huw Davies <huw(a)codeweavers.com> Signed-off-by: Alexandre Julliard <julliard(a)winehq.org> --- dlls/netapi32/unixlib.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/dlls/netapi32/unixlib.c b/dlls/netapi32/unixlib.c index 23881b470d9..c6b389950f7 100644 --- a/dlls/netapi32/unixlib.c +++ b/dlls/netapi32/unixlib.c @@ -72,7 +72,7 @@ static DWORD netapi_wcstoumbs( const WCHAR *src, char *dst, DWORD dstlen ) static DWORD netapi_umbstowcs( const char *src, WCHAR *dst, DWORD dstlen ) { - if (!dst) return (strlen( src ) + 1) * sizeof(WCHAR); + if (!dst) return strlen( src ) + 1; return ntdll_umbstowcs( src, strlen( src ) + 1, dst, dstlen ); }
participants (1)
-
Alexandre Julliard