Module: wine Branch: master Commit: 5eb040253c90a20ed070f643e479ed32b83e49fa URL: http://source.winehq.org/git/wine.git/?a=commit;h=5eb040253c90a20ed070f643e4...
Author: Erich E. Hoover erich.e.hoover@gmail.com Date: Tue Feb 25 19:10:58 2014 -0700
hhctrl.ocx: Support delimited filenames for HH_DISPLAY_TOPIC data.
---
dlls/hhctrl.ocx/hhctrl.c | 15 ++++++++++++++- 1 file changed, 14 insertions(+), 1 deletion(-)
diff --git a/dlls/hhctrl.ocx/hhctrl.c b/dlls/hhctrl.ocx/hhctrl.c index 8b42569..86a31f5 100644 --- a/dlls/hhctrl.ocx/hhctrl.c +++ b/dlls/hhctrl.ocx/hhctrl.c @@ -203,7 +203,20 @@ HWND WINAPI HtmlHelpW(HWND caller, LPCWSTR filename, UINT command, DWORD_PTR dat case HH_DISPLAY_TOPIC: case HH_DISPLAY_TOC: if (data) - index = (const WCHAR *)data; + { + static const WCHAR delimW[] = {':',':',0}; + const WCHAR *i = (const WCHAR *)data; + + index = strstrW(i, delimW); + if(index) + { + if(memcmp(info->pCHMInfo->szFile, i, index-i)) + FIXME("Opening a CHM file in the context of another is not supported.\n"); + index += strlenW(delimW); + } + else + index = i; + } break; }