[PATCH 0/1] MR11067: hhctrl: return a nonzero cookie from HH_INITIALIZE
Fixes launch of Simberian Simbeor PCB simulation software. It seems it must do a check to see if the cookie is 0. The software is not open source but a view-only license can be acquired for free by making an account on their website. This doesn't seem to be documented behavior (https://learn.microsoft.com/en-us/previous-versions/windows/desktop/htmlhelp...) does not mention that 0 is an invalid cookie, but Windows must not return zero otherwise this app would not work on windows? -- https://gitlab.winehq.org/wine/wine/-/merge_requests/11067
From: Russell Greene <russellgreene8@gmail.com> Fixes launch of Simberian Simbeor PCB simulation software --- dlls/hhctrl.ocx/hhctrl.c | 10 ++++++++++ 1 file changed, 10 insertions(+) diff --git a/dlls/hhctrl.ocx/hhctrl.c b/dlls/hhctrl.ocx/hhctrl.c index 14e18bbaf98..45efa1792e5 100644 --- a/dlls/hhctrl.ocx/hhctrl.c +++ b/dlls/hhctrl.ocx/hhctrl.c @@ -377,6 +377,16 @@ HWND WINAPI HtmlHelpW(HWND caller, LPCWSTR filename, UINT command, DWORD_PTR dat free(window); return 0; } + case HH_INITIALIZE: { + /* Return a non-zero cookie that is later passed back to + * HH_UNINITIALIZE. Applications check this value and treat a NULL + * cookie as an initialization failure. */ + if (data) + *(DWORD *)data = 1; + return (HWND)1; + } + case HH_UNINITIALIZE: + return 0; default: FIXME("HH case %s not handled.\n", command_to_string( command )); } -- GitLab https://gitlab.winehq.org/wine/wine/-/merge_requests/11067
participants (1)
-
Russell Greene -
Russell Greene (@russelltg)