[PATCH] ntdll/tests: Fix the test_process_params() size check.
Zebediah Figura (she/her)
zfigura at codeweavers.com
Wed Jun 23 10:38:24 CDT 2021
On 6/23/21 6:15 AM, Francois Gouget wrote:
> Signed-off-by: Francois Gouget <fgouget at codeweavers.com>
> ---
> Because it all depends on rounding, this failure would only happen in
> the 64-bit ntdll:env test on the TestBot.
> Here I could only reproduce it when starting ntdll:env from a Windows
> process rather than directly from ./wine, both for 32- and 64-bit.
> ---
> dlls/ntdll/tests/env.c | 1 +
> 1 file changed, 1 insertion(+)
>
> diff --git a/dlls/ntdll/tests/env.c b/dlls/ntdll/tests/env.c
> index 9cfbf9eb435..351f8d5df5a 100644
> --- a/dlls/ntdll/tests/env.c
> +++ b/dlls/ntdll/tests/env.c
> @@ -456,6 +456,7 @@ static void test_process_params(void)
> pos = check_string( cur_params, &cur_params->ShellInfo, NULL, pos );
> pos = check_string( cur_params, &cur_params->RuntimeInfo, NULL, pos );
> /* environment may follow */
> + pos = align(pos, sizeof(void *));
> str = (WCHAR *)pos;
> if (pos - (UINT_PTR)cur_params < cur_params->Size) str += get_env_length(str);
> ok( (char *)str == (char *)cur_params + cur_params->Size,
>
I did some extensive tests of this; Windows really doesn't align the
initial parameters (and only initial parameters) size, but Wine does.
More information about the wine-devel
mailing list