Zhiyi Zhang : uxtheme: Save temporary system metrics to a struct in memory.
Module: wine Branch: master Commit: aefcd057b1a85c159b1e3bdc2bb6f77f9d77f670 URL: https://source.winehq.org/git/wine.git/?a=commit;h=aefcd057b1a85c159b1e3bdc2... Author: Zhiyi Zhang <zzhang(a)codeweavers.com> Date: Thu Oct 21 10:06:16 2021 +0800 uxtheme: Save temporary system metrics to a struct in memory. So that temporary system metrics are not saved in the registry. Saving them to the registry creates a race condition when two processes are trying to activate theming at the same time, one process might save themed system metrics instead of unthemed system metrics to the registry. The race condition will be more apparent when initializing a wine prefix after theming is turned on by default in wine.inf. This patch refactors the system metric helper functions to use an in-memory struct and is a prerequisite to remove the race condition. Signed-off-by: Zhiyi Zhang <zzhang(a)codeweavers.com> Signed-off-by: Alexandre Julliard <julliard(a)winehq.org> --- dlls/uxtheme/system.c | 340 +++++++++++++++++++++++--------------------------- 1 file changed, 159 insertions(+), 181 deletions(-) Diff: https://source.winehq.org/git/wine.git/?a=commitdiff;h=aefcd057b1a85c159b1e3...
participants (1)
-
Alexandre Julliard