Fixes https://bugs.winehq.org/show_bug.cgi?id=57987.
In the case of that issue, it does not crash anymore, and the settings are now correctly saved.
-- v2: comctl32: Avoid segfault in PROPSHEET_DoCommand when psInfo is NULL.
From: Yuri Hérouard yuri.herouard@gmail.com
--- dlls/comctl32/propsheet.c | 2 ++ 1 file changed, 2 insertions(+)
diff --git a/dlls/comctl32/propsheet.c b/dlls/comctl32/propsheet.c index 44b24a56a07..d397f85870d 100644 --- a/dlls/comctl32/propsheet.c +++ b/dlls/comctl32/propsheet.c @@ -3326,6 +3326,8 @@ static BOOL PROPSHEET_DoCommand(HWND hwnd, WORD wID) { PropSheetInfo* psInfo = GetPropW(hwnd, PropSheetInfoStr);
+ if (psInfo == NULL) break; + /* don't overwrite ID_PSRESTARTWINDOWS or ID_PSREBOOTSYSTEM */ if (psInfo->result == 0) psInfo->result = IDOK;
On Sun Mar 23 01:49:47 2025 +0000, Nikolay Sivov wrote:
I think it's a reasonable change. One remaining issue though - please force push with your full name in the patch author field.
Done.
This merge request was approved by Nikolay Sivov.
This merge request was approved by Zhiyi Zhang.