mshtml: Allow '#' to be the first char of resource name in res protocol.

This commit is contained in:
Jacek Caban 2014-12-24 16:31:50 +01:00 committed by Alexandre Julliard
parent 5135144d3a
commit fecbc88daf
3 changed files with 7 additions and 1 deletions

View file

@ -649,7 +649,7 @@ static HRESULT WINAPI ResProtocol_Start(IInternetProtocol *iface, LPCWSTR szUrl,
/* Ignore query and hash parts. */
if((ptr = strchrW(url_file, '?')))
*ptr = 0;
if((ptr = strchrW(url_file, '#')))
if(*url_file && (ptr = strchrW(url_file+1, '#')))
*ptr = 0;
hdll = LoadLibraryExW(url_dll, NULL, LOAD_LIBRARY_AS_DATAFILE);

View file

@ -606,6 +606,9 @@ static void test_res_protocol(void)
if(GetProcAddress(LoadLibraryA("urlmon.dll"), "CreateUri")) {
test_res_url("/test/dir/dir2/res.html?query_part");
test_res_url("/test/dir/dir2/res.html#hash_part");
test_res_url("/#123");
test_res_url("/#23/#123");
test_res_url("/#123#456");
}else {
win_skip("IUri not supported\n");
}

View file

@ -40,6 +40,9 @@ blank.html HTML "blank.html"
/* @makedep: blank.html */
blank2.html HTML "blank.html"
/* @makedep: blank.html */
123 HTML "blank.html"
/* @makedep: test_tlb.tlb */
1 TYPELIB test_tlb.tlb