Skip to content
Snippets Groups Projects
Commit 7ad5e1bc authored by Vladimir Panteleev's avatar Vladimir Panteleev Committed by Alexandre Julliard
Browse files

kernelbase: Preserve last error when GetEnvironmentVariableA succeeds.


Avoid clobbering last error with NO_ERROR when GetEnvironmentVariableA
succeeds, matching the behavior of GetEnvironmentVariableW and
Windows.

Instead of naively saving and restoring the last error, call
RtlQueryEnvironmentVariable_U directly to avoid unnecessarily setting
it in the first place.

Signed-off-by: default avatarVladimir Panteleev <git@vladimir.panteleev.md>
Signed-off-by: default avatarGijs Vermeulen <gijsvrm@gmail.com>
Signed-off-by: Alexandre Julliard's avatarAlexandre Julliard <julliard@winehq.org>
parent 3c1edaaa
Branches
Tags
No related merge requests found
Loading
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Please register or to comment