The tests are added at the end to avoid restructuring older tests.
-- v2: urlmon/tests: Test flags for getting properties. urlmon: Support Uri_DISPLAY_IDN_HOST. urlmon: Support Uri_PUNYCODE_IDN_HOST. urlmon: Support Uri_DISPLAY_NO_FRAGMENT. urlmon: Support Uri_HOST_IDN.
From: Zhiyi Zhang zzhang@codeweavers.com
--- dlls/urlmon/uri.c | 35 ++++++++++++++++++++++++++++++----- 1 file changed, 30 insertions(+), 5 deletions(-)
diff --git a/dlls/urlmon/uri.c b/dlls/urlmon/uri.c index 9d31df22862..e7ed113b2df 100644 --- a/dlls/urlmon/uri.c +++ b/dlls/urlmon/uri.c @@ -525,11 +525,19 @@ void find_domain_name(const WCHAR *host, DWORD host_len, return; } } else if(last_tld-host < 3) - /* Anything less than 3 characters is considered part + { + /* Anything less than 3 ASCII characters is considered part * of the TLD name. * Ex: ak.uk -> Has no domain name. */ - return; + for(p = host; p < last_tld; p++) { + if(!is_ascii(*p)) + break; + } + + if(p == last_tld) + return; + }
/* Otherwise the domain name is the whole host name. */ *domain_start = 0; @@ -1339,11 +1347,21 @@ static BOOL parse_reg_name(const WCHAR **ptr, parse_data *data, DWORD extras) { /* If the host is empty, then it's an unknown host type. */ if(data->host_len == 0 || is_res) data->host_type = Uri_HOST_UNKNOWN; - else + else { + unsigned int i; + data->host_type = Uri_HOST_DNS;
- TRACE("(%p %p %lx): Parsed reg-name. host=%s len=%ld\n", ptr, data, extras, - debugstr_wn(data->host, data->host_len), data->host_len); + for(i = 0; i < data->host_len; i++) { + if(!is_ascii(data->host[i])) { + data->host_type = Uri_HOST_IDN; + break; + } + } + } + + TRACE("(%p %p %lx): Parsed reg-name. host=%s len=%ld type=%d\n", ptr, data, extras, + debugstr_wn(data->host, data->host_len), data->host_len, data->host_type); return TRUE; }
@@ -2276,6 +2294,13 @@ static BOOL canonicalize_host(const parse_data *data, Uri *uri, DWORD flags, BOO
uri->host_type = Uri_HOST_IPV6; break; + + case Uri_HOST_IDN: + uri->host_type = Uri_HOST_IDN; + if(!canonicalize_reg_name(data, uri, flags, computeOnly)) + return FALSE; + + break; case Uri_HOST_UNKNOWN: if(data->host_len > 0 || data->scheme_type != URL_SCHEME_FILE) { uri->host_start = uri->canon_len;
From: Zhiyi Zhang zzhang@codeweavers.com
--- dlls/urlmon/uri.c | 42 +++++++++++++++++++++++++++++++++--------- 1 file changed, 33 insertions(+), 9 deletions(-)
diff --git a/dlls/urlmon/uri.c b/dlls/urlmon/uri.c index e7ed113b2df..3cd8c23b58a 100644 --- a/dlls/urlmon/uri.c +++ b/dlls/urlmon/uri.c @@ -3898,12 +3898,14 @@ static HRESULT WINAPI Uri_GetPropertyBSTR(IUri *iface, Uri_PROPERTY uriProp, BST return E_INVALIDARG; }
- /* Don't have support for flags yet. */ - if(dwFlags) { + if(dwFlags != 0 && dwFlags != Uri_DISPLAY_NO_FRAGMENT) { FIXME("(%p)->(%d %p %lx)\n", This, uriProp, pbstrProperty, dwFlags); return E_NOTIMPL; }
+ if(dwFlags == Uri_DISPLAY_NO_FRAGMENT && uriProp != Uri_PROPERTY_DISPLAY_URI) + return E_INVALIDARG; + switch(uriProp) { case Uri_PROPERTY_ABSOLUTE_URI: if(This->display_modifiers & URI_DISPLAY_NO_ABSOLUTE_URI) { @@ -3969,18 +3971,32 @@ static HRESULT WINAPI Uri_GetPropertyBSTR(IUri *iface, Uri_PROPERTY uriProp, BST * scheme types. */ if(This->scheme_type != URL_SCHEME_UNKNOWN && This->userinfo_start > -1) { - *pbstrProperty = SysAllocStringLen(NULL, This->canon_len-This->userinfo_len); + unsigned int length = This->canon_len-This->userinfo_len; + + /* Skip fragment if Uri_DISPLAY_NO_FRAGMENT is specified */ + if(dwFlags == Uri_DISPLAY_NO_FRAGMENT && This->fragment_start > -1) + length -= This->fragment_len; + + *pbstrProperty = SysAllocStringLen(NULL, length);
if(*pbstrProperty) { /* Copy everything before the userinfo over. */ memcpy(*pbstrProperty, This->canon_uri, This->userinfo_start*sizeof(WCHAR)); + /* Copy everything after the userinfo over. */ + length -= This->userinfo_start+1; memcpy(*pbstrProperty+This->userinfo_start, - This->canon_uri+This->userinfo_start+This->userinfo_len+1, - (This->canon_len-(This->userinfo_start+This->userinfo_len+1))*sizeof(WCHAR)); + This->canon_uri+This->userinfo_start+This->userinfo_len+1, length*sizeof(WCHAR)); } - } else - *pbstrProperty = SysAllocString(This->canon_uri); + } else { + unsigned int length = This->canon_len; + + /* Skip fragment if Uri_DISPLAY_NO_FRAGMENT is specified */ + if(dwFlags == Uri_DISPLAY_NO_FRAGMENT && This->fragment_start > -1) + length -= This->fragment_len; + + *pbstrProperty = SysAllocStringLen(This->canon_uri, length); + }
if(!(*pbstrProperty)) hres = E_OUTOFMEMORY; @@ -4181,8 +4197,7 @@ static HRESULT WINAPI Uri_GetPropertyLength(IUri *iface, Uri_PROPERTY uriProp, D if(uriProp > Uri_PROPERTY_STRING_LAST) return E_INVALIDARG;
- /* Don't have support for flags yet. */ - if(dwFlags) { + if(dwFlags != 0 && dwFlags != Uri_DISPLAY_NO_FRAGMENT) { FIXME("(%p)->(%d %p %lx)\n", This, uriProp, pcchProperty, dwFlags); return E_NOTIMPL; } @@ -4226,6 +4241,9 @@ static HRESULT WINAPI Uri_GetPropertyLength(IUri *iface, Uri_PROPERTY uriProp, D else *pcchProperty = This->canon_len;
+ if(dwFlags == Uri_DISPLAY_NO_FRAGMENT && This->fragment_start > -1) + *pcchProperty -= This->fragment_len; + hres = S_OK; break; case Uri_PROPERTY_DOMAIN: @@ -4299,6 +4317,12 @@ static HRESULT WINAPI Uri_GetPropertyLength(IUri *iface, Uri_PROPERTY uriProp, D hres = E_NOTIMPL; }
+ if(hres == S_OK + && (dwFlags == Uri_DISPLAY_NO_FRAGMENT && uriProp != Uri_PROPERTY_DISPLAY_URI)) { + *pcchProperty = 0; + hres = E_INVALIDARG; + } + return hres; }
From: Zhiyi Zhang zzhang@codeweavers.com
--- dlls/urlmon/uri.c | 67 +++++++++++++++++++++++++++++++++++++++++------ 1 file changed, 59 insertions(+), 8 deletions(-)
diff --git a/dlls/urlmon/uri.c b/dlls/urlmon/uri.c index 3cd8c23b58a..5f4cd9ae77a 100644 --- a/dlls/urlmon/uri.c +++ b/dlls/urlmon/uri.c @@ -3898,12 +3898,14 @@ static HRESULT WINAPI Uri_GetPropertyBSTR(IUri *iface, Uri_PROPERTY uriProp, BST return E_INVALIDARG; }
- if(dwFlags != 0 && dwFlags != Uri_DISPLAY_NO_FRAGMENT) { + if(dwFlags != 0 && dwFlags != Uri_DISPLAY_NO_FRAGMENT && dwFlags != Uri_PUNYCODE_IDN_HOST) { FIXME("(%p)->(%d %p %lx)\n", This, uriProp, pbstrProperty, dwFlags); return E_NOTIMPL; }
- if(dwFlags == Uri_DISPLAY_NO_FRAGMENT && uriProp != Uri_PROPERTY_DISPLAY_URI) + if((dwFlags == Uri_DISPLAY_NO_FRAGMENT && uriProp != Uri_PROPERTY_DISPLAY_URI) + || (dwFlags == Uri_PUNYCODE_IDN_HOST && uriProp != Uri_PROPERTY_ABSOLUTE_URI + && uriProp != Uri_PROPERTY_DOMAIN && uriProp != Uri_PROPERTY_HOST)) return E_INVALIDARG;
switch(uriProp) { @@ -3911,6 +3913,21 @@ static HRESULT WINAPI Uri_GetPropertyBSTR(IUri *iface, Uri_PROPERTY uriProp, BST if(This->display_modifiers & URI_DISPLAY_NO_ABSOLUTE_URI) { *pbstrProperty = SysAllocStringLen(NULL, 0); hres = S_FALSE; + } + /* Uri_PUNYCODE_IDN_HOST doesn't remove user info containing only "@" and ":@" */ + else if (dwFlags == Uri_PUNYCODE_IDN_HOST && This->host_type == Uri_HOST_IDN && This->host_start > -1) { + unsigned int punycode_host_len; + + punycode_host_len = IdnToAscii(0, This->canon_uri+This->host_start, This->host_len, NULL, 0); + *pbstrProperty = SysAllocStringLen(NULL, This->canon_len-This->host_len+punycode_host_len); + hres = S_OK; + if(*pbstrProperty) { + memcpy(*pbstrProperty, This->canon_uri, This->host_start*sizeof(WCHAR)); + IdnToAscii(0, This->canon_uri+This->host_start, This->host_len, *pbstrProperty+This->host_start, punycode_host_len); + memcpy(*pbstrProperty+This->host_start+punycode_host_len, + This->canon_uri+This->host_start+This->host_len, + (This->canon_len-This->host_start-This->host_len)*sizeof(WCHAR)); + } } else { if(This->scheme_type != URL_SCHEME_UNKNOWN && This->userinfo_start > -1) { if(This->userinfo_len == 0) { @@ -4006,8 +4023,20 @@ static HRESULT WINAPI Uri_GetPropertyBSTR(IUri *iface, Uri_PROPERTY uriProp, BST break; case Uri_PROPERTY_DOMAIN: if(This->domain_offset > -1) { - *pbstrProperty = SysAllocStringLen(This->canon_uri+This->host_start+This->domain_offset, - This->host_len-This->domain_offset); + if(dwFlags == Uri_PUNYCODE_IDN_HOST && This->host_type == Uri_HOST_IDN) { + unsigned int punycode_length; + + punycode_length = IdnToAscii(0, This->canon_uri+This->host_start+This->domain_offset, + This->host_len-This->domain_offset, NULL, 0); + *pbstrProperty = SysAllocStringLen(NULL, punycode_length); + if (*pbstrProperty) + IdnToAscii(0, This->canon_uri+This->host_start+This->domain_offset, + This->host_len-This->domain_offset, *pbstrProperty, punycode_length); + } else { + *pbstrProperty = SysAllocStringLen(This->canon_uri+This->host_start+This->domain_offset, + This->host_len-This->domain_offset); + } + hres = S_OK; } else { *pbstrProperty = SysAllocStringLen(NULL, 0); @@ -4050,6 +4079,14 @@ static HRESULT WINAPI Uri_GetPropertyBSTR(IUri *iface, Uri_PROPERTY uriProp, BST /* The '[' and ']' aren't included for IPv6 addresses. */ if(This->host_type == Uri_HOST_IPV6) *pbstrProperty = SysAllocStringLen(This->canon_uri+This->host_start+1, This->host_len-2); + else if(dwFlags == Uri_PUNYCODE_IDN_HOST && This->host_type == Uri_HOST_IDN) { + unsigned int punycode_length; + + punycode_length = IdnToAscii(0, This->canon_uri+This->host_start, This->host_len, NULL, 0); + *pbstrProperty = SysAllocStringLen(NULL, punycode_length); + if (*pbstrProperty) + IdnToAscii(0, This->canon_uri+This->host_start, This->host_len, *pbstrProperty, punycode_length); + } else *pbstrProperty = SysAllocStringLen(This->canon_uri+This->host_start, This->host_len);
@@ -4197,7 +4234,7 @@ static HRESULT WINAPI Uri_GetPropertyLength(IUri *iface, Uri_PROPERTY uriProp, D if(uriProp > Uri_PROPERTY_STRING_LAST) return E_INVALIDARG;
- if(dwFlags != 0 && dwFlags != Uri_DISPLAY_NO_FRAGMENT) { + if(dwFlags != 0 && dwFlags != Uri_DISPLAY_NO_FRAGMENT && dwFlags != Uri_PUNYCODE_IDN_HOST) { FIXME("(%p)->(%d %p %lx)\n", This, uriProp, pcchProperty, dwFlags); return E_NOTIMPL; } @@ -4207,6 +4244,12 @@ static HRESULT WINAPI Uri_GetPropertyLength(IUri *iface, Uri_PROPERTY uriProp, D if(This->display_modifiers & URI_DISPLAY_NO_ABSOLUTE_URI) { *pcchProperty = 0; hres = S_FALSE; + } + /* Uri_PUNYCODE_IDN_HOST doesn't remove user info containing only "@" and ":@" */ + else if(dwFlags == Uri_PUNYCODE_IDN_HOST && This->host_type == Uri_HOST_IDN && This->host_start > -1) { + unsigned int punycode_host_len = IdnToAscii(0, This->canon_uri+This->host_start, This->host_len, NULL, 0); + *pcchProperty = This->canon_len - This->host_len + punycode_host_len; + hres = S_OK; } else { if(This->scheme_type != URL_SCHEME_UNKNOWN) { if(This->userinfo_start > -1 && This->userinfo_len == 0) @@ -4247,8 +4290,12 @@ static HRESULT WINAPI Uri_GetPropertyLength(IUri *iface, Uri_PROPERTY uriProp, D hres = S_OK; break; case Uri_PROPERTY_DOMAIN: - if(This->domain_offset > -1) - *pcchProperty = This->host_len - This->domain_offset; + if(This->domain_offset > -1) { + if(dwFlags == Uri_PUNYCODE_IDN_HOST && This->host_type == Uri_HOST_IDN) + *pcchProperty = IdnToAscii(0, This->canon_uri+This->host_start+This->domain_offset, This->host_len-This->domain_offset, NULL, 0); + else + *pcchProperty = This->host_len - This->domain_offset; + } else *pcchProperty = 0;
@@ -4274,6 +4321,8 @@ static HRESULT WINAPI Uri_GetPropertyLength(IUri *iface, Uri_PROPERTY uriProp, D /* '[' and ']' aren't included in the length. */ if(This->host_type == Uri_HOST_IPV6) *pcchProperty -= 2; + else if(dwFlags == Uri_PUNYCODE_IDN_HOST && This->host_type == Uri_HOST_IDN && This->host_start > -1) + *pcchProperty = IdnToAscii(0, This->canon_uri+This->host_start, This->host_len, NULL, 0);
hres = (This->host_start > -1) ? S_OK : S_FALSE; break; @@ -4318,7 +4367,9 @@ static HRESULT WINAPI Uri_GetPropertyLength(IUri *iface, Uri_PROPERTY uriProp, D }
if(hres == S_OK - && (dwFlags == Uri_DISPLAY_NO_FRAGMENT && uriProp != Uri_PROPERTY_DISPLAY_URI)) { + && ((dwFlags == Uri_DISPLAY_NO_FRAGMENT && uriProp != Uri_PROPERTY_DISPLAY_URI) + || (dwFlags == Uri_PUNYCODE_IDN_HOST && uriProp != Uri_PROPERTY_ABSOLUTE_URI + && uriProp != Uri_PROPERTY_DOMAIN && uriProp != Uri_PROPERTY_HOST))) { *pcchProperty = 0; hres = E_INVALIDARG; }
From: Zhiyi Zhang zzhang@codeweavers.com
Uri_DISPLAY_IDN_HOST makes the hostname in Uri_PROPERTY_ABSOLUTE_URI, Uri_PROPERTY_DOMAIN and Uri_PROPERTY_HOST appear in punycode or Unicode as it would appear in the Uri_PROPERTY_DISPLAY_URI property. IDNs appears in Unicode on some Windows version and in punycode on others. Wine chose to display Unicode for Uri_PROPERTY_DISPLAY_URI. So no need to add special handling for Uri_DISPLAY_IDN_HOST at the moment because they already display in Unicode. --- dlls/urlmon/uri.c | 18 +++++++++++------- 1 file changed, 11 insertions(+), 7 deletions(-)
diff --git a/dlls/urlmon/uri.c b/dlls/urlmon/uri.c index 5f4cd9ae77a..cb5266518d1 100644 --- a/dlls/urlmon/uri.c +++ b/dlls/urlmon/uri.c @@ -3898,13 +3898,14 @@ static HRESULT WINAPI Uri_GetPropertyBSTR(IUri *iface, Uri_PROPERTY uriProp, BST return E_INVALIDARG; }
- if(dwFlags != 0 && dwFlags != Uri_DISPLAY_NO_FRAGMENT && dwFlags != Uri_PUNYCODE_IDN_HOST) { - FIXME("(%p)->(%d %p %lx)\n", This, uriProp, pbstrProperty, dwFlags); - return E_NOTIMPL; - } + if(dwFlags != 0 && dwFlags != Uri_DISPLAY_NO_FRAGMENT && dwFlags != Uri_PUNYCODE_IDN_HOST + && dwFlags != Uri_DISPLAY_IDN_HOST) + return E_INVALIDARG;
if((dwFlags == Uri_DISPLAY_NO_FRAGMENT && uriProp != Uri_PROPERTY_DISPLAY_URI) || (dwFlags == Uri_PUNYCODE_IDN_HOST && uriProp != Uri_PROPERTY_ABSOLUTE_URI + && uriProp != Uri_PROPERTY_DOMAIN && uriProp != Uri_PROPERTY_HOST) + || (dwFlags == Uri_DISPLAY_IDN_HOST && uriProp != Uri_PROPERTY_ABSOLUTE_URI && uriProp != Uri_PROPERTY_DOMAIN && uriProp != Uri_PROPERTY_HOST)) return E_INVALIDARG;
@@ -4234,9 +4235,10 @@ static HRESULT WINAPI Uri_GetPropertyLength(IUri *iface, Uri_PROPERTY uriProp, D if(uriProp > Uri_PROPERTY_STRING_LAST) return E_INVALIDARG;
- if(dwFlags != 0 && dwFlags != Uri_DISPLAY_NO_FRAGMENT && dwFlags != Uri_PUNYCODE_IDN_HOST) { - FIXME("(%p)->(%d %p %lx)\n", This, uriProp, pcchProperty, dwFlags); - return E_NOTIMPL; + if(dwFlags != 0 && dwFlags != Uri_DISPLAY_NO_FRAGMENT && dwFlags != Uri_PUNYCODE_IDN_HOST + && dwFlags != Uri_DISPLAY_IDN_HOST) { + *pcchProperty = 0; + return E_INVALIDARG; }
switch(uriProp) { @@ -4369,6 +4371,8 @@ static HRESULT WINAPI Uri_GetPropertyLength(IUri *iface, Uri_PROPERTY uriProp, D if(hres == S_OK && ((dwFlags == Uri_DISPLAY_NO_FRAGMENT && uriProp != Uri_PROPERTY_DISPLAY_URI) || (dwFlags == Uri_PUNYCODE_IDN_HOST && uriProp != Uri_PROPERTY_ABSOLUTE_URI + && uriProp != Uri_PROPERTY_DOMAIN && uriProp != Uri_PROPERTY_HOST) + || (dwFlags == Uri_DISPLAY_IDN_HOST && uriProp != Uri_PROPERTY_ABSOLUTE_URI && uriProp != Uri_PROPERTY_DOMAIN && uriProp != Uri_PROPERTY_HOST))) { *pcchProperty = 0; hres = E_INVALIDARG;
From: Zhiyi Zhang zzhang@codeweavers.com
--- dlls/urlmon/tests/uri.c | 834 ++++++++++++++++++++++++++++++---------- 1 file changed, 627 insertions(+), 207 deletions(-)
diff --git a/dlls/urlmon/tests/uri.c b/dlls/urlmon/tests/uri.c index cc6f5796fdd..2c9f7736ffa 100644 --- a/dlls/urlmon/tests/uri.c +++ b/dlls/urlmon/tests/uri.c @@ -131,13 +131,14 @@ typedef struct _uri_properties { DWORD create_flags; HRESULT create_expected; BOOL create_todo; + DWORD flags;
uri_str_property str_props[URI_STR_PROPERTY_COUNT]; uri_dword_property dword_props[URI_DWORD_PROPERTY_COUNT]; } uri_properties;
static const uri_properties uri_tests[] = { - { "http://www.winehq.org/tests/../tests/../..", 0, S_OK, FALSE, + { "http://www.winehq.org/tests/../tests/../..", 0, S_OK, FALSE, 0, { {"http://www.winehq.org/%22,S_OK,FALSE%7D, /* ABSOLUTE_URI */ {"www.winehq.org",S_OK,FALSE}, /* AUTHORITY */ @@ -162,7 +163,7 @@ static const uri_properties uri_tests[] = { {URLZONE_INVALID,E_NOTIMPL,FALSE} /* ZONE */ } }, - { "http://winehq.org/tests/.././tests", 0, S_OK, FALSE, + { "http://winehq.org/tests/.././tests", 0, S_OK, FALSE, 0, { {"http://winehq.org/tests%22,S_OK,FALSE%7D, {"winehq.org",S_OK,FALSE}, @@ -187,7 +188,7 @@ static const uri_properties uri_tests[] = { {URLZONE_INVALID,E_NOTIMPL,FALSE} } }, - { "HtTp://www.winehq.org/tests/..?query=x&return=y", 0, S_OK, FALSE, + { "HtTp://www.winehq.org/tests/..?query=x&return=y", 0, S_OK, FALSE, 0, { {"http://www.winehq.org/?query=x&return=y%22,S_OK,FALSE%7D, {"www.winehq.org",S_OK,FALSE}, @@ -212,7 +213,7 @@ static const uri_properties uri_tests[] = { {URLZONE_INVALID,E_NOTIMPL,FALSE}, } }, - { "HtTpS://www.winehq.org/tests/..?query=x&return=y", 0, S_OK, FALSE, + { "HtTpS://www.winehq.org/tests/..?query=x&return=y", 0, S_OK, FALSE, 0, { {"https://www.winehq.org/?query=x&return=y%22,S_OK,FALSE%7D, {"www.winehq.org",S_OK,FALSE}, @@ -237,7 +238,7 @@ static const uri_properties uri_tests[] = { {URLZONE_INVALID,E_NOTIMPL,FALSE}, } }, - { "hTTp://us%45r%3Ainfo@examp%4CE.com:80/path/a/b/./c/../%2E%2E/Forbidden'<|> Characters", 0, S_OK, FALSE, + { "hTTp://us%45r%3Ainfo@examp%4CE.com:80/path/a/b/./c/../%2E%2E/Forbidden'<|> Characters", 0, S_OK, FALSE, 0, { {"http://usEr%3Ainfo@example.com/path/a/Forbidden%27%3C%7C%3E%20Characters%22,..., {"usEr%3Ainfo@example.com",S_OK,FALSE}, @@ -262,7 +263,7 @@ static const uri_properties uri_tests[] = { {URLZONE_INVALID,E_NOTIMPL,FALSE}, } }, - { "ftp://winepass:wine@ftp.winehq.org:9999/dir/foo bar.txt", 0, S_OK, FALSE, + { "ftp://winepass:wine@ftp.winehq.org:9999/dir/foo bar.txt", 0, S_OK, FALSE, 0, { {"ftp://winepass:wine@ftp.winehq.org:9999/dir/foo%20bar.txt",S_OK,FALSE}, {"winepass:wine@ftp.winehq.org:9999",S_OK,FALSE}, @@ -287,7 +288,7 @@ static const uri_properties uri_tests[] = { {URLZONE_INVALID,E_NOTIMPL,FALSE} } }, - { "file://c:\tests\../tests/foo%20bar.mp3", 0, S_OK, FALSE, + { "file://c:\tests\../tests/foo%20bar.mp3", 0, S_OK, FALSE, 0, { {"file:///c:/tests/foo%2520bar.mp3",S_OK,FALSE}, {"",S_FALSE,FALSE}, @@ -312,7 +313,7 @@ static const uri_properties uri_tests[] = { {URLZONE_INVALID,E_NOTIMPL,FALSE} } }, - { "file://c:\tests\../tests/foo%20bar.mp3", Uri_CREATE_NO_CANONICALIZE, S_OK, FALSE, + { "file://c:\tests\../tests/foo%20bar.mp3", Uri_CREATE_NO_CANONICALIZE, S_OK, FALSE, 0, { {"file:///c:/tests/../tests/foo%2520bar.mp3",S_OK,FALSE}, {"",S_FALSE,FALSE}, @@ -337,7 +338,7 @@ static const uri_properties uri_tests[] = { {URLZONE_INVALID,E_NOTIMPL,FALSE} } }, - { "FILE://localhost/test dir\../tests/test%20file.README.txt", 0, S_OK, FALSE, + { "FILE://localhost/test dir\../tests/test%20file.README.txt", 0, S_OK, FALSE, 0, { {"file:///tests/test%20file.README.txt",S_OK,FALSE}, {"",S_FALSE,FALSE}, @@ -362,7 +363,7 @@ static const uri_properties uri_tests[] = { {URLZONE_INVALID,E_NOTIMPL,FALSE} } }, - { "file:///z:/test dir/README.txt", 0, S_OK, FALSE, + { "file:///z:/test dir/README.txt", 0, S_OK, FALSE, 0, { {"file:///z:/test%20dir/README.txt",S_OK}, {"",S_FALSE}, @@ -387,7 +388,7 @@ static const uri_properties uri_tests[] = { {URLZONE_INVALID,E_NOTIMPL,FALSE} } }, - { "file:///z:/test dir/README.txt#hash part", 0, S_OK, FALSE, + { "file:///z:/test dir/README.txt#hash part", 0, S_OK, FALSE, 0, { {"file:///z:/test%20dir/README.txt#hash%20part",S_OK}, {"",S_FALSE}, @@ -412,7 +413,7 @@ static const uri_properties uri_tests[] = { {URLZONE_INVALID,E_NOTIMPL,FALSE} } }, - { "urn:nothing:should:happen here", 0, S_OK, FALSE, + { "urn:nothing:should:happen here", 0, S_OK, FALSE, 0, { {"urn:nothing:should:happen here",S_OK,FALSE}, {"",S_FALSE,FALSE}, @@ -437,7 +438,7 @@ static const uri_properties uri_tests[] = { {URLZONE_INVALID,E_NOTIMPL,FALSE} } }, - { "http://127.0.0.1/tests/../test dir/./test.txt", 0, S_OK, FALSE, + { "http://127.0.0.1/tests/../test dir/./test.txt", 0, S_OK, FALSE, 0, { {"http://127.0.0.1/test%20dir/test.txt%22,S_OK,FALSE%7D, {"127.0.0.1",S_OK,FALSE}, @@ -462,7 +463,7 @@ static const uri_properties uri_tests[] = { {URLZONE_INVALID,E_NOTIMPL,FALSE} } }, - { "http://%5BFEDC:BA98:7654:3210:FEDC:BA98:7654:3210]", 0, S_OK, FALSE, + { "http://%5BFEDC:BA98:7654:3210:FEDC:BA98:7654:3210]", 0, S_OK, FALSE, 0, { {"http://%5Bfedc:ba98:7654:3210:fedc:ba98:7654:3210%5D/%22,S_OK,FALSE%7D, {"[fedc:ba98:7654:3210:fedc:ba98:7654:3210]",S_OK,FALSE}, @@ -487,7 +488,7 @@ static const uri_properties uri_tests[] = { {URLZONE_INVALID,E_NOTIMPL,FALSE} } }, - { "ftp://[::13.1.68.3]", 0, S_OK, FALSE, + { "ftp://[::13.1.68.3]", 0, S_OK, FALSE, 0, { {"ftp://[::13.1.68.3]/",S_OK,FALSE}, {"[::13.1.68.3]",S_OK,FALSE}, @@ -512,7 +513,7 @@ static const uri_properties uri_tests[] = { {URLZONE_INVALID,E_NOTIMPL,FALSE} } }, - { "http://%5BFEDC:BA98:0:0:0:0:0:3210]", 0, S_OK, FALSE, + { "http://%5BFEDC:BA98:0:0:0:0:0:3210]", 0, S_OK, FALSE, 0, { {"http://%5Bfedc:ba98::3210%5D/%22,S_OK,FALSE%7D, {"[fedc:ba98::3210]",S_OK,FALSE}, @@ -537,7 +538,7 @@ static const uri_properties uri_tests[] = { {URLZONE_INVALID,E_NOTIMPL,FALSE} } }, - { "1234://www.winehq.org", 0, S_OK, FALSE, + { "1234://www.winehq.org", 0, S_OK, FALSE, 0, { {"1234://www.winehq.org/",S_OK,FALSE}, {"www.winehq.org",S_OK,FALSE}, @@ -563,7 +564,7 @@ static const uri_properties uri_tests[] = { } }, /* Test's to make sure the parser/canonicalizer handles implicit file schemes correctly. */ - { "C:/test/test.mp3", Uri_CREATE_ALLOW_IMPLICIT_FILE_SCHEME, S_OK, FALSE, + { "C:/test/test.mp3", Uri_CREATE_ALLOW_IMPLICIT_FILE_SCHEME, S_OK, FALSE, 0, { {"file:///C:/test/test.mp3",S_OK,FALSE}, {"",S_FALSE,FALSE}, @@ -589,7 +590,7 @@ static const uri_properties uri_tests[] = { } }, /* Test's to make sure the parser/canonicalizer handles implicit file schemes correctly. */ - { "\\Server/test.mp3", Uri_CREATE_ALLOW_IMPLICIT_FILE_SCHEME, S_OK, FALSE, + { "\\Server/test.mp3", Uri_CREATE_ALLOW_IMPLICIT_FILE_SCHEME, S_OK, FALSE, 0, { {"file://server/test.mp3",S_OK,FALSE}, {"server",S_OK,FALSE}, @@ -614,7 +615,7 @@ static const uri_properties uri_tests[] = { {URLZONE_INVALID,E_NOTIMPL,FALSE} } }, - { "C:/test/test.mp3#fragment|part", Uri_CREATE_ALLOW_IMPLICIT_FILE_SCHEME|Uri_CREATE_FILE_USE_DOS_PATH|Uri_CREATE_NO_DECODE_EXTRA_INFO, S_OK, FALSE, + { "C:/test/test.mp3#fragment|part", Uri_CREATE_ALLOW_IMPLICIT_FILE_SCHEME|Uri_CREATE_FILE_USE_DOS_PATH|Uri_CREATE_NO_DECODE_EXTRA_INFO, S_OK, FALSE, 0, { {"file://C:\test\test.mp3#fragment|part",S_OK,FALSE}, {"",S_FALSE,FALSE}, @@ -639,7 +640,7 @@ static const uri_properties uri_tests[] = { {URLZONE_INVALID,E_NOTIMPL,FALSE} } }, - { "C:/test/test.mp3?query|part", Uri_CREATE_ALLOW_IMPLICIT_FILE_SCHEME|Uri_CREATE_FILE_USE_DOS_PATH|Uri_CREATE_NO_DECODE_EXTRA_INFO, S_OK, FALSE, + { "C:/test/test.mp3?query|part", Uri_CREATE_ALLOW_IMPLICIT_FILE_SCHEME|Uri_CREATE_FILE_USE_DOS_PATH|Uri_CREATE_NO_DECODE_EXTRA_INFO, S_OK, FALSE, 0, { {"file://C:\test\test.mp3?query|part",S_OK,FALSE}, {"",S_FALSE,FALSE}, @@ -664,7 +665,7 @@ static const uri_properties uri_tests[] = { {URLZONE_INVALID,E_NOTIMPL,FALSE} } }, - { "C:/test/test.mp3?query|part#hash|part", Uri_CREATE_ALLOW_IMPLICIT_FILE_SCHEME|Uri_CREATE_FILE_USE_DOS_PATH|Uri_CREATE_NO_DECODE_EXTRA_INFO, S_OK, FALSE, + { "C:/test/test.mp3?query|part#hash|part", Uri_CREATE_ALLOW_IMPLICIT_FILE_SCHEME|Uri_CREATE_FILE_USE_DOS_PATH|Uri_CREATE_NO_DECODE_EXTRA_INFO, S_OK, FALSE, 0, { {"file://C:\test\test.mp3?query|part#hash|part",S_OK,FALSE}, {"",S_FALSE,FALSE}, @@ -689,7 +690,7 @@ static const uri_properties uri_tests[] = { {URLZONE_INVALID,E_NOTIMPL,FALSE} } }, - { "www.winehq.org/test", Uri_CREATE_ALLOW_IMPLICIT_WILDCARD_SCHEME, S_OK, FALSE, + { "www.winehq.org/test", Uri_CREATE_ALLOW_IMPLICIT_WILDCARD_SCHEME, S_OK, FALSE, 0, { {"*:www.winehq.org/test",S_OK,FALSE}, {"www.winehq.org",S_OK,FALSE}, @@ -715,7 +716,7 @@ static const uri_properties uri_tests[] = { } }, /* Valid since the '*' is the only character in the scheme name. */ - { "*:www.winehq.org/test", 0, S_OK, FALSE, + { "*:www.winehq.org/test", 0, S_OK, FALSE, 0, { {"*:www.winehq.org/test",S_OK,FALSE}, {"www.winehq.org",S_OK,FALSE}, @@ -740,7 +741,7 @@ static const uri_properties uri_tests[] = { {URLZONE_INVALID,E_NOTIMPL,FALSE} } }, - { "/../some dir/test.ext", Uri_CREATE_ALLOW_RELATIVE, S_OK, FALSE, + { "/../some dir/test.ext", Uri_CREATE_ALLOW_RELATIVE, S_OK, FALSE, 0, { {"/../some dir/test.ext",S_OK,FALSE}, {"",S_FALSE,FALSE}, @@ -765,7 +766,7 @@ static const uri_properties uri_tests[] = { {URLZONE_INVALID,E_NOTIMPL,FALSE} } }, - { "//implicit/wildcard/uri scheme", Uri_CREATE_ALLOW_RELATIVE|Uri_CREATE_ALLOW_IMPLICIT_WILDCARD_SCHEME, S_OK, FALSE, + { "//implicit/wildcard/uri scheme", Uri_CREATE_ALLOW_RELATIVE|Uri_CREATE_ALLOW_IMPLICIT_WILDCARD_SCHEME, S_OK, FALSE, 0, { {"*://implicit/wildcard/uri%20scheme",S_OK,FALSE}, {"",S_OK,FALSE}, @@ -791,7 +792,7 @@ static const uri_properties uri_tests[] = { } }, /* URI is considered opaque since CREATE_NO_CRACK_UNKNOWN_SCHEMES is set and it's an unknown scheme. */ - { "zip://google.com", Uri_CREATE_NO_CRACK_UNKNOWN_SCHEMES, S_OK, FALSE, + { "zip://google.com", Uri_CREATE_NO_CRACK_UNKNOWN_SCHEMES, S_OK, FALSE, 0, { {"zip:/.//google.com",S_OK,FALSE}, {"",S_FALSE,FALSE}, @@ -817,7 +818,7 @@ static const uri_properties uri_tests[] = { } }, /* Windows uses the first occurrence of ':' to delimit the userinfo. */ - { "ftp://user:pass:word@winehq.org/", 0, S_OK, FALSE, + { "ftp://user:pass:word@winehq.org/", 0, S_OK, FALSE, 0, { {"ftp://user:pass:word@winehq.org/",S_OK,FALSE}, {"user:pass:word@winehq.org",S_OK,FALSE}, @@ -843,7 +844,7 @@ static const uri_properties uri_tests[] = { } }, /* Make sure % encoded unreserved characters are decoded. */ - { "ftp://w%49%4Ee:PA%53%53@ftp.google.com/", 0, S_OK, FALSE, + { "ftp://w%49%4Ee:PA%53%53@ftp.google.com/", 0, S_OK, FALSE, 0, { {"ftp://wINe:PASS@ftp.google.com/",S_OK,FALSE}, {"wINe:PASS@ftp.google.com",S_OK,FALSE}, @@ -869,7 +870,7 @@ static const uri_properties uri_tests[] = { } }, /* Make sure % encoded characters which are NOT unreserved are NOT decoded. */ - { "ftp://w%5D%5Be:PA%7B%7D@ftp.google.com/", 0, S_OK, FALSE, + { "ftp://w%5D%5Be:PA%7B%7D@ftp.google.com/", 0, S_OK, FALSE, 0, { {"ftp://w%5D%5Be:PA%7B%7D@ftp.google.com/",S_OK,FALSE}, {"w%5D%5Be:PA%7B%7D@ftp.google.com",S_OK,FALSE}, @@ -895,7 +896,7 @@ static const uri_properties uri_tests[] = { } }, /* You're allowed to have an empty password portion in the userinfo section. */ - { "ftp://empty:@ftp.google.com/", 0, S_OK, FALSE, + { "ftp://empty:@ftp.google.com/", 0, S_OK, FALSE, 0, { {"ftp://empty:@ftp.google.com/",S_OK,FALSE}, {"empty:@ftp.google.com",S_OK,FALSE}, @@ -921,7 +922,7 @@ static const uri_properties uri_tests[] = { } }, /* Make sure forbidden characters in "userinfo" get encoded. */ - { "ftp://" "weird@ftp.google.com/", 0, S_OK, FALSE, + { "ftp://" "weird@ftp.google.com/", 0, S_OK, FALSE, 0, { {"ftp://%22%20%22weird@ftp.google.com/",S_OK,FALSE}, {"%22%20%22weird@ftp.google.com",S_OK,FALSE}, @@ -947,7 +948,7 @@ static const uri_properties uri_tests[] = { } }, /* Make sure the forbidden characters don't get percent encoded. */ - { "ftp://" "weird@ftp.google.com/", Uri_CREATE_NO_ENCODE_FORBIDDEN_CHARACTERS, S_OK, FALSE, + { "ftp://" "weird@ftp.google.com/", Uri_CREATE_NO_ENCODE_FORBIDDEN_CHARACTERS, S_OK, FALSE, 0, { {"ftp://" "weird@ftp.google.com/",S_OK,FALSE}, {"" "weird@ftp.google.com",S_OK,FALSE}, @@ -973,7 +974,7 @@ static const uri_properties uri_tests[] = { } }, /* Make sure already percent encoded characters don't get unencoded. */ - { "ftp://"%20"weird@ftp.google.com/"%20"weird", Uri_CREATE_NO_ENCODE_FORBIDDEN_CHARACTERS, S_OK, FALSE, + { "ftp://"%20"weird@ftp.google.com/"%20"weird", Uri_CREATE_NO_ENCODE_FORBIDDEN_CHARACTERS, S_OK, FALSE, 0, { {"ftp://"%20"weird@ftp.google.com/"%20"weird",S_OK,FALSE}, {""%20"weird@ftp.google.com",S_OK,FALSE}, @@ -999,7 +1000,7 @@ static const uri_properties uri_tests[] = { } }, /* Allowed to have invalid % encoded because it's an unknown scheme type. */ - { "zip://%xy:word@winehq.org/", 0, S_OK, FALSE, + { "zip://%xy:word@winehq.org/", 0, S_OK, FALSE, 0, { {"zip://%xy:word@winehq.org/",S_OK,FALSE}, {"%xy:word@winehq.org",S_OK,FALSE}, @@ -1027,7 +1028,7 @@ static const uri_properties uri_tests[] = { /* Unreserved, percent encoded characters aren't decoded in the userinfo because the scheme * isn't known. */ - { "zip://%2E:%52%53ord@winehq.org/", 0, S_OK, FALSE, + { "zip://%2E:%52%53ord@winehq.org/", 0, S_OK, FALSE, 0, { {"zip://%2E:%52%53ord@winehq.org/",S_OK,FALSE}, {"%2E:%52%53ord@winehq.org",S_OK,FALSE}, @@ -1052,7 +1053,7 @@ static const uri_properties uri_tests[] = { {URLZONE_INVALID,E_NOTIMPL,FALSE} } }, - { "ftp://[](),'test':word@winehq.org/", 0, S_OK, FALSE, + { "ftp://[](),'test':word@winehq.org/", 0, S_OK, FALSE, 0, { {"ftp://[](),'test':word@winehq.org/",S_OK,FALSE}, {"[](),'test':word@winehq.org",S_OK,FALSE}, @@ -1077,7 +1078,7 @@ static const uri_properties uri_tests[] = { {URLZONE_INVALID,E_NOTIMPL,FALSE} } }, - { "ftp://test?:word@winehq.org/", 0, S_OK, FALSE, + { "ftp://test?:word@winehq.org/", 0, S_OK, FALSE, 0, { {"ftp://test/?:word@winehq.org/",S_OK,FALSE}, {"test",S_OK,FALSE}, @@ -1102,7 +1103,7 @@ static const uri_properties uri_tests[] = { {URLZONE_INVALID,E_NOTIMPL,FALSE} } }, - { "ftp://test#:word@winehq.org/", 0, S_OK, FALSE, + { "ftp://test#:word@winehq.org/", 0, S_OK, FALSE, 0, { {"ftp://test/#:word@winehq.org/",S_OK,FALSE}, {"test",S_OK,FALSE}, @@ -1128,7 +1129,7 @@ static const uri_properties uri_tests[] = { } }, /* Allowed to have a backslash in the userinfo since it's an unknown scheme. */ - { "zip://test\:word@winehq.org/", 0, S_OK, FALSE, + { "zip://test\:word@winehq.org/", 0, S_OK, FALSE, 0, { {"zip://test\:word@winehq.org/",S_OK,FALSE}, {"test\:word@winehq.org",S_OK,FALSE}, @@ -1154,7 +1155,7 @@ static const uri_properties uri_tests[] = { } }, /* It normalizes IPv4 addresses correctly. */ - { "http://127.000.000.100/", 0, S_OK, FALSE, + { "http://127.000.000.100/", 0, S_OK, FALSE, 0, { {"http://127.0.0.100/%22,S_OK,FALSE%7D, {"127.0.0.100",S_OK,FALSE}, @@ -1179,7 +1180,7 @@ static const uri_properties uri_tests[] = { {URLZONE_INVALID,E_NOTIMPL,FALSE} } }, - { "http://127.0.0.1:8000", 0, S_OK, FALSE, + { "http://127.0.0.1:8000", 0, S_OK, FALSE, 0, { {"http://127.0.0.1:8000/%22,S_OK%7D, {"127.0.0.1:8000",S_OK}, @@ -1205,7 +1206,7 @@ static const uri_properties uri_tests[] = { } }, /* Make sure it normalizes partial IPv4 addresses correctly. */ - { "http://127.0/", 0, S_OK, FALSE, + { "http://127.0/", 0, S_OK, FALSE, 0, { {"http://127.0.0.0/%22,S_OK,FALSE%7D, {"127.0.0.0",S_OK,FALSE}, @@ -1231,7 +1232,7 @@ static const uri_properties uri_tests[] = { } }, /* Make sure it converts implicit IPv4's correctly. */ - { "http://123456/", 0, S_OK, FALSE, + { "http://123456/", 0, S_OK, FALSE, 0, { {"http://0.1.226.64/%22,S_OK,FALSE%7D, {"0.1.226.64",S_OK,FALSE}, @@ -1257,7 +1258,7 @@ static const uri_properties uri_tests[] = { } }, /* UINT_MAX */ - { "http://4294967295/", 0, S_OK, FALSE, + { "http://4294967295/", 0, S_OK, FALSE, 0, { {"http://255.255.255.255/%22,S_OK,FALSE%7D, {"255.255.255.255",S_OK,FALSE}, @@ -1283,7 +1284,7 @@ static const uri_properties uri_tests[] = { } }, /* UINT_MAX+1 */ - { "http://4294967296/", 0, S_OK, FALSE, + { "http://4294967296/", 0, S_OK, FALSE, 0, { {"http://4294967296/%22,S_OK,FALSE%7D, {"4294967296",S_OK,FALSE}, @@ -1309,7 +1310,7 @@ static const uri_properties uri_tests[] = { } }, /* Window's doesn't normalize IP address for unknown schemes. */ - { "1234://4294967295/", 0, S_OK, FALSE, + { "1234://4294967295/", 0, S_OK, FALSE, 0, { {"1234://4294967295/",S_OK,FALSE}, {"4294967295",S_OK,FALSE}, @@ -1335,7 +1336,7 @@ static const uri_properties uri_tests[] = { } }, /* Window's doesn't normalize IP address for unknown schemes. */ - { "1234://127.001/", 0, S_OK, FALSE, + { "1234://127.001/", 0, S_OK, FALSE, 0, { {"1234://127.001/",S_OK,FALSE}, {"127.001",S_OK,FALSE}, @@ -1360,7 +1361,7 @@ static const uri_properties uri_tests[] = { {URLZONE_INVALID,E_NOTIMPL,FALSE} } }, - { "http://%5BFEDC:BA98::3210]", 0, S_OK, FALSE, + { "http://%5BFEDC:BA98::3210]", 0, S_OK, FALSE, 0, { {"http://%5Bfedc:ba98::3210%5D/%22,S_OK,FALSE%7D, {"[fedc:ba98::3210]",S_OK,FALSE}, @@ -1385,7 +1386,7 @@ static const uri_properties uri_tests[] = { {URLZONE_INVALID,E_NOTIMPL,FALSE} } }, - { "http://[::]", 0, S_OK, FALSE, + { "http://[::]", 0, S_OK, FALSE, 0, { {"http://%5B::%5D/%22,S_OK,FALSE%7D, {"[::]",S_OK,FALSE}, @@ -1410,7 +1411,7 @@ static const uri_properties uri_tests[] = { {URLZONE_INVALID,E_NOTIMPL,FALSE} } }, - { "http://%5BFEDC:BA98::]", 0, S_OK, FALSE, + { "http://%5BFEDC:BA98::]", 0, S_OK, FALSE, 0, { {"http://%5Bfedc:ba98::%5D/%22,S_OK,FALSE%7D, {"[fedc:ba98::]",S_OK,FALSE}, @@ -1436,7 +1437,7 @@ static const uri_properties uri_tests[] = { } }, /* Valid even with 2 byte elision because it doesn't appear the beginning or end. */ - { "http://%5B1::3:4:5:6:7:8]", 0, S_OK, FALSE, + { "http://%5B1::3:4:5:6:7:8]", 0, S_OK, FALSE, 0, { {"http://%5B1:0:3:4:5:6:7:8%5D/%22,S_OK,FALSE%7D, {"[1:0:3:4:5:6:7:8]",S_OK,FALSE}, @@ -1461,7 +1462,7 @@ static const uri_properties uri_tests[] = { {URLZONE_INVALID,E_NOTIMPL,FALSE} } }, - { "http://%5Bv2.34%5D/", 0, S_OK, FALSE, + { "http://%5Bv2.34%5D/", 0, S_OK, FALSE, 0, { {"http://%5Bv2.34%5D/%22,S_OK,FALSE%7D, {"[v2.34]",S_OK,FALSE}, @@ -1487,7 +1488,7 @@ static const uri_properties uri_tests[] = { } }, /* Windows ignores ':' if they appear after a '[' on a non-IPLiteral host. */ - { "http://%5Bxyz:12345.com/test", 0, S_OK, FALSE, + { "http://%5Bxyz:12345.com/test", 0, S_OK, FALSE, 0, { {"http://%5Bxyz:12345.com/test%22,S_OK,FALSE%7D, {"[xyz:12345.com",S_OK,FALSE}, @@ -1515,7 +1516,7 @@ static const uri_properties uri_tests[] = { /* Valid URI since the '[' and ']' don't appear at the beginning and end * of the host name (respectively). */ - { "ftp://www.[works].com/", 0, S_OK, FALSE, + { "ftp://www.[works].com/", 0, S_OK, FALSE, 0, { {"ftp://www.[works].com/",S_OK,FALSE}, {"www.[works].com",S_OK,FALSE}, @@ -1541,7 +1542,7 @@ static const uri_properties uri_tests[] = { } }, /* Considers ':' a delimiter since it appears after the ']'. */ - { "http://www.google.com%5D:12345/", 0, S_OK, FALSE, + { "http://www.google.com%5D:12345/", 0, S_OK, FALSE, 0, { {"http://www.google.com%5D:12345/%22,S_OK,FALSE%7D, {"www.google.com]:12345",S_OK,FALSE}, @@ -1567,7 +1568,7 @@ static const uri_properties uri_tests[] = { } }, /* Unknown scheme types can have invalid % encoded data in the hostname. */ - { "zip://w%XXw%GEw.google.com/", 0, S_OK, FALSE, + { "zip://w%XXw%GEw.google.com/", 0, S_OK, FALSE, 0, { {"zip://w%XXw%GEw.google.com/",S_OK,FALSE}, {"w%XXw%GEw.google.com",S_OK,FALSE}, @@ -1593,7 +1594,7 @@ static const uri_properties uri_tests[] = { } }, /* Unknown scheme types hostname doesn't get lower cased. */ - { "zip://GOOGLE.com/", 0, S_OK, FALSE, + { "zip://GOOGLE.com/", 0, S_OK, FALSE, 0, { {"zip://GOOGLE.com/",S_OK,FALSE}, {"GOOGLE.com",S_OK,FALSE}, @@ -1619,7 +1620,7 @@ static const uri_properties uri_tests[] = { } }, /* Hostname gets lower-cased for known scheme types. */ - { "http://WWW.GOOGLE.com/", 0, S_OK, FALSE, + { "http://WWW.GOOGLE.com/", 0, S_OK, FALSE, 0, { {"http://www.google.com/%22,S_OK,FALSE%7D, {"www.google.com",S_OK,FALSE}, @@ -1647,7 +1648,7 @@ static const uri_properties uri_tests[] = { /* Characters that get % encoded in the hostname also have their percent * encoded forms lower cased. */ - { "http://www.%7Cgoogle%7C.com/", 0, S_OK, FALSE, + { "http://www.%7Cgoogle%7C.com/", 0, S_OK, FALSE, 0, { {"http://www.%7cgoogle%7c.com/%22,S_OK,FALSE%7D, {"www.%7cgoogle%7c.com",S_OK,FALSE}, @@ -1673,7 +1674,7 @@ static const uri_properties uri_tests[] = { } }, /* IPv4 addresses attached to IPv6 can be included in elisions. */ - { "http://%5B1:2:3:4:5:6:0.0.0.0]", 0, S_OK, FALSE, + { "http://%5B1:2:3:4:5:6:0.0.0.0]", 0, S_OK, FALSE, 0, { {"http://%5B1:2:3:4:5:6::%5D/%22,S_OK,FALSE%7D, {"[1:2:3:4:5:6::]",S_OK,FALSE}, @@ -1699,7 +1700,7 @@ static const uri_properties uri_tests[] = { } }, /* IPv4 addresses get normalized. */ - { "http://%5B::001.002.003.000]", 0, S_OK, FALSE, + { "http://%5B::001.002.003.000]", 0, S_OK, FALSE, 0, { {"http://%5B::1.2.3.0%5D/%22,S_OK,FALSE%7D, {"[::1.2.3.0]",S_OK,FALSE}, @@ -1724,7 +1725,7 @@ static const uri_properties uri_tests[] = { {URLZONE_INVALID,E_NOTIMPL,FALSE} } }, - { "http://%5B::5efe:1.2.3.4]", 0, S_OK, FALSE, + { "http://%5B::5efe:1.2.3.4]", 0, S_OK, FALSE, 0, { {"http://%5B::5efe:1.2.3.4%5D/%22,S_OK,FALSE%7D, {"[::5efe:1.2.3.4]",S_OK,FALSE}, @@ -1750,7 +1751,7 @@ static const uri_properties uri_tests[] = { } }, /* Windows doesn't do anything to IPv6's in unknown schemes. */ - { "zip://[0001:0:000:0004:0005:0006:001.002.003.000]", 0, S_OK, FALSE, + { "zip://[0001:0:000:0004:0005:0006:001.002.003.000]", 0, S_OK, FALSE, 0, { {"zip://[0001:0:000:0004:0005:0006:001.002.003.000]/",S_OK,FALSE}, {"[0001:0:000:0004:0005:0006:001.002.003.000]",S_OK,FALSE}, @@ -1776,7 +1777,7 @@ static const uri_properties uri_tests[] = { } }, /* IPv4 address is converted into 2 h16 components. */ - { "http://%5Bffff::192.222.111.32]", 0, S_OK, FALSE, + { "http://%5Bffff::192.222.111.32]", 0, S_OK, FALSE, 0, { {"http://%5Bffff::c0de:6f20%5D/%22,S_OK,FALSE%7D, {"[ffff::c0de:6f20]",S_OK,FALSE}, @@ -1802,7 +1803,7 @@ static const uri_properties uri_tests[] = { } }, /* Max value for a port. */ - { "http://google.com:65535", 0, S_OK, FALSE, + { "http://google.com:65535", 0, S_OK, FALSE, 0, { {"http://google.com:65535/%22,S_OK,FALSE%7D, {"google.com:65535",S_OK,FALSE}, @@ -1827,7 +1828,7 @@ static const uri_properties uri_tests[] = { {URLZONE_INVALID,E_NOTIMPL,FALSE} } }, - { "zip://google.com:65536", 0, S_OK, FALSE, + { "zip://google.com:65536", 0, S_OK, FALSE, 0, { {"zip://google.com:65536/",S_OK,FALSE}, {"google.com:65536",S_OK,FALSE}, @@ -1852,7 +1853,7 @@ static const uri_properties uri_tests[] = { {URLZONE_INVALID,E_NOTIMPL,FALSE} } }, - { "zip://google.com:65536:25", 0, S_OK, FALSE, + { "zip://google.com:65536:25", 0, S_OK, FALSE, 0, { {"zip://google.com:65536:25/",S_OK,FALSE}, {"google.com:65536:25",S_OK,FALSE}, @@ -1877,7 +1878,7 @@ static const uri_properties uri_tests[] = { {URLZONE_INVALID,E_NOTIMPL,FALSE} } }, - { "zip://[::ffff]:abcd", 0, S_OK, FALSE, + { "zip://[::ffff]:abcd", 0, S_OK, FALSE, 0, { {"zip://[::ffff]:abcd/",S_OK,FALSE}, {"[::ffff]:abcd",S_OK,FALSE}, @@ -1902,7 +1903,7 @@ static const uri_properties uri_tests[] = { {URLZONE_INVALID,E_NOTIMPL,FALSE} } }, - { "zip://127.0.0.1:abcd", 0, S_OK, FALSE, + { "zip://127.0.0.1:abcd", 0, S_OK, FALSE, 0, { {"zip://127.0.0.1:abcd/",S_OK,FALSE}, {"127.0.0.1:abcd",S_OK,FALSE}, @@ -1928,7 +1929,7 @@ static const uri_properties uri_tests[] = { } }, /* Port is just copied over. */ - { "http://google.com:00035", Uri_CREATE_NO_CANONICALIZE, S_OK, FALSE, + { "http://google.com:00035", Uri_CREATE_NO_CANONICALIZE, S_OK, FALSE, 0, { {"http://google.com:00035%22,S_OK,FALSE%7D, {"google.com:00035",S_OK,FALSE}, @@ -1954,7 +1955,7 @@ static const uri_properties uri_tests[] = { } }, /* Default port is copied over. */ - { "http://google.com:80", Uri_CREATE_NO_CANONICALIZE, S_OK, FALSE, + { "http://google.com:80", Uri_CREATE_NO_CANONICALIZE, S_OK, FALSE, 0, { {"http://google.com:80%22,S_OK,FALSE%7D, {"google.com:80",S_OK,FALSE}, @@ -1979,7 +1980,7 @@ static const uri_properties uri_tests[] = { {URLZONE_INVALID,E_NOTIMPL,FALSE} } }, - { "http://google.com.uk", 0, S_OK, FALSE, + { "http://google.com.uk", 0, S_OK, FALSE, 0, { {"http://google.com.uk/%22,S_OK,FALSE%7D, {"google.com.uk",S_OK,FALSE}, @@ -2004,7 +2005,7 @@ static const uri_properties uri_tests[] = { {URLZONE_INVALID,E_NOTIMPL,FALSE} } }, - { "http://google.co.uk", 0, S_OK, FALSE, + { "http://google.co.uk", 0, S_OK, FALSE, 0, { {"http://google.co.uk/%22,S_OK,FALSE%7D, {"google.co.uk",S_OK,FALSE}, @@ -2029,7 +2030,7 @@ static const uri_properties uri_tests[] = { {URLZONE_INVALID,E_NOTIMPL,FALSE} } }, - { "http://google.com.com", 0, S_OK, FALSE, + { "http://google.com.com", 0, S_OK, FALSE, 0, { {"http://google.com.com/%22,S_OK,FALSE%7D, {"google.com.com",S_OK,FALSE}, @@ -2054,7 +2055,7 @@ static const uri_properties uri_tests[] = { {URLZONE_INVALID,E_NOTIMPL,FALSE} } }, - { "http://google.uk.1", 0, S_OK, FALSE, + { "http://google.uk.1", 0, S_OK, FALSE, 0, { {"http://google.uk.1/%22,S_OK,FALSE%7D, {"google.uk.1",S_OK,FALSE}, @@ -2080,7 +2081,7 @@ static const uri_properties uri_tests[] = { } }, /* Since foo isn't a recognized 3 character TLD it's considered the domain name. */ - { "http://google.foo.uk", 0, S_OK, FALSE, + { "http://google.foo.uk", 0, S_OK, FALSE, 0, { {"http://google.foo.uk/%22,S_OK,FALSE%7D, {"google.foo.uk",S_OK,FALSE}, @@ -2105,7 +2106,7 @@ static const uri_properties uri_tests[] = { {URLZONE_INVALID,E_NOTIMPL,FALSE} } }, - { "http://.com", 0, S_OK, FALSE, + { "http://.com", 0, S_OK, FALSE, 0, { {"http://.com/%22,S_OK,FALSE%7D, {".com",S_OK,FALSE}, @@ -2130,7 +2131,7 @@ static const uri_properties uri_tests[] = { {URLZONE_INVALID,E_NOTIMPL,FALSE} } }, - { "http://.uk", 0, S_OK, FALSE, + { "http://.uk", 0, S_OK, FALSE, 0, { {"http://.uk/%22,S_OK,FALSE%7D, {".uk",S_OK,FALSE}, @@ -2155,7 +2156,7 @@ static const uri_properties uri_tests[] = { {URLZONE_INVALID,E_NOTIMPL,FALSE} } }, - { "http://www.co.google.com.%5B]", 0, S_OK, FALSE, + { "http://www.co.google.com.%5B]", 0, S_OK, FALSE, 0, { {"http://www.co.google.com.%5B%5D/%22,S_OK,FALSE%7D, {"www.co.google.com.[]",S_OK,FALSE}, @@ -2180,7 +2181,7 @@ static const uri_properties uri_tests[] = { {URLZONE_INVALID,E_NOTIMPL,FALSE} } }, - { "http://co.uk", 0, S_OK, FALSE, + { "http://co.uk", 0, S_OK, FALSE, 0, { {"http://co.uk/%22,S_OK,FALSE%7D, {"co.uk",S_OK,FALSE}, @@ -2205,7 +2206,7 @@ static const uri_properties uri_tests[] = { {URLZONE_INVALID,E_NOTIMPL,FALSE} } }, - { "http://www.co.google.us.test", 0, S_OK, FALSE, + { "http://www.co.google.us.test", 0, S_OK, FALSE, 0, { {"http://www.co.google.us.test/%22,S_OK,FALSE%7D, {"www.co.google.us.test",S_OK,FALSE}, @@ -2230,7 +2231,7 @@ static const uri_properties uri_tests[] = { {URLZONE_INVALID,E_NOTIMPL,FALSE} } }, - { "http://gov.uk", 0, S_OK, FALSE, + { "http://gov.uk", 0, S_OK, FALSE, 0, { {"http://gov.uk/%22,S_OK,FALSE%7D, {"gov.uk",S_OK,FALSE}, @@ -2255,7 +2256,7 @@ static const uri_properties uri_tests[] = { {URLZONE_INVALID,E_NOTIMPL,FALSE} } }, - { "zip://www.google.com\test", Uri_CREATE_NO_CANONICALIZE, S_OK, FALSE, + { "zip://www.google.com\test", Uri_CREATE_NO_CANONICALIZE, S_OK, FALSE, 0, { {"zip://www.google.com\test",S_OK,FALSE}, {"www.google.com\test",S_OK,FALSE}, @@ -2280,7 +2281,7 @@ static const uri_properties uri_tests[] = { {URLZONE_INVALID,E_NOTIMPL,FALSE} } }, - { "urn:excepts:bad:%XY:encoded", 0, S_OK, FALSE, + { "urn:excepts:bad:%XY:encoded", 0, S_OK, FALSE, 0, { {"urn:excepts:bad:%XY:encoded",S_OK,FALSE}, {"",S_FALSE,FALSE}, @@ -2308,7 +2309,7 @@ static const uri_properties uri_tests[] = { /* Since the original URI doesn't contain an extra '/' before the path no % encoded values * are decoded and all '%' are encoded. */ - { "file://C:/te%3Es%2Et/tes%t.mp3", 0, S_OK, FALSE, + { "file://C:/te%3Es%2Et/tes%t.mp3", 0, S_OK, FALSE, 0, { {"file:///C:/te%253Es%252Et/tes%25t.mp3",S_OK,FALSE}, {"",S_FALSE,FALSE}, @@ -2336,7 +2337,7 @@ static const uri_properties uri_tests[] = { /* Since there's a '/' in front of the drive letter, any percent encoded, non-forbidden character * is decoded and only %'s in front of invalid hex digits are encoded. */ - { "file:///C:/te%3Es%2Et/t%23es%t.mp3", 0, S_OK, FALSE, + { "file:///C:/te%3Es%2Et/t%23es%t.mp3", 0, S_OK, FALSE, 0, { {"file:///C:/te%3Es.t/t#es%25t.mp3",S_OK,FALSE}, {"",S_FALSE,FALSE}, @@ -2362,7 +2363,7 @@ static const uri_properties uri_tests[] = { } }, /* Only unreserved percent encoded characters are decoded for known schemes that aren't file. */ - { "http://%5B::001.002.003.000%5D/%3F%23%2E%54/test", 0, S_OK, FALSE, + { "http://%5B::001.002.003.000%5D/%3F%23%2E%54/test", 0, S_OK, FALSE, 0, { {"http://%5B::1.2.3.0%5D/%3F%23.T/test%22,S_OK,FALSE%7D, {"[::1.2.3.0]",S_OK,FALSE}, @@ -2388,7 +2389,7 @@ static const uri_properties uri_tests[] = { } }, /* Forbidden characters are always encoded for file URIs. */ - { "file:///C:/"test"/test.mp3", Uri_CREATE_NO_ENCODE_FORBIDDEN_CHARACTERS, S_OK, FALSE, + { "file:///C:/"test"/test.mp3", Uri_CREATE_NO_ENCODE_FORBIDDEN_CHARACTERS, S_OK, FALSE, 0, { {"file:///C:/%22test%22/test.mp3",S_OK,FALSE}, {"",S_FALSE,FALSE}, @@ -2414,7 +2415,7 @@ static const uri_properties uri_tests[] = { } }, /* Forbidden characters are never encoded for unknown scheme types. */ - { "1234://4294967295/<|>" test<|>", 0, S_OK, FALSE, + { "1234://4294967295/<|>" test<|>", 0, S_OK, FALSE, 0, { {"1234://4294967295/<|>" test<|>",S_OK,FALSE}, {"4294967295",S_OK,FALSE}, @@ -2440,7 +2441,7 @@ static const uri_properties uri_tests[] = { } }, /* Make sure forbidden characters are percent encoded. */ - { "http://gov.uk/<|> test<|>", 0, S_OK, FALSE, + { "http://gov.uk/<|> test<|>", 0, S_OK, FALSE, 0, { {"http://gov.uk/%3C%7C%3E%20test%3C%7C%3E%22,S_OK,FALSE%7D, {"gov.uk",S_OK,FALSE}, @@ -2465,7 +2466,7 @@ static const uri_properties uri_tests[] = { {URLZONE_INVALID,E_NOTIMPL,FALSE} } }, - { "http://gov.uk/test/../test2/././../test3/.././././", 0, S_OK, FALSE, + { "http://gov.uk/test/../test2/././../test3/.././././", 0, S_OK, FALSE, 0, { {"http://gov.uk/%22,S_OK,FALSE%7D, {"gov.uk",S_OK,FALSE}, @@ -2490,7 +2491,7 @@ static const uri_properties uri_tests[] = { {URLZONE_INVALID,E_NOTIMPL,FALSE} } }, - { "http://gov.uk/test/test2/../../..", 0, S_OK, FALSE, + { "http://gov.uk/test/test2/../../..", 0, S_OK, FALSE, 0, { {"http://gov.uk/%22,S_OK,FALSE%7D, {"gov.uk",S_OK,FALSE}, @@ -2515,7 +2516,7 @@ static const uri_properties uri_tests[] = { {URLZONE_INVALID,E_NOTIMPL,FALSE} } }, - { "http://gov.uk/test/test2/../../.", 0, S_OK, FALSE, + { "http://gov.uk/test/test2/../../.", 0, S_OK, FALSE, 0, { {"http://gov.uk/%22,S_OK,FALSE%7D, {"gov.uk",S_OK,FALSE}, @@ -2540,7 +2541,7 @@ static const uri_properties uri_tests[] = { {URLZONE_INVALID,E_NOTIMPL,FALSE} } }, - { "file://c:\tests\../tests\./.\..\foo%20bar.mp3", 0, S_OK, FALSE, + { "file://c:\tests\../tests\./.\..\foo%20bar.mp3", 0, S_OK, FALSE, 0, { {"file:///c:/foo%2520bar.mp3",S_OK,FALSE}, {"",S_FALSE,FALSE}, @@ -2566,7 +2567,7 @@ static const uri_properties uri_tests[] = { } }, /* Dot removal happens for unknown scheme types. */ - { "zip://gov.uk/test/test2/../../.", 0, S_OK, FALSE, + { "zip://gov.uk/test/test2/../../.", 0, S_OK, FALSE, 0, { {"zip://gov.uk/",S_OK,FALSE}, {"gov.uk",S_OK,FALSE}, @@ -2592,7 +2593,7 @@ static const uri_properties uri_tests[] = { } }, /* Dot removal doesn't happen if NO_CANONICALIZE is set. */ - { "http://gov.uk/test/test2/../../.", Uri_CREATE_NO_CANONICALIZE, S_OK, FALSE, + { "http://gov.uk/test/test2/../../.", Uri_CREATE_NO_CANONICALIZE, S_OK, FALSE, 0, { {"http://gov.uk/test/test2/../../.%22,S_OK,FALSE%7D, {"gov.uk",S_OK,FALSE}, @@ -2618,7 +2619,7 @@ static const uri_properties uri_tests[] = { } }, /* Dot removal doesn't happen for wildcard scheme types. */ - { "*:gov.uk/test/test2/../../.", 0, S_OK, FALSE, + { "*:gov.uk/test/test2/../../.", 0, S_OK, FALSE, 0, { {"*:gov.uk/test/test2/../../.",S_OK,FALSE}, {"gov.uk",S_OK,FALSE}, @@ -2644,7 +2645,7 @@ static const uri_properties uri_tests[] = { } }, /* Forbidden characters are encoded for opaque known scheme types. */ - { "mailto:"acco<|>unt@example.com"", 0, S_OK, FALSE, + { "mailto:"acco<|>unt@example.com"", 0, S_OK, FALSE, 0, { {"mailto:%22acco%3C%7C%3Eunt@example.com%22",S_OK,FALSE}, {"",S_FALSE,FALSE}, @@ -2669,7 +2670,7 @@ static const uri_properties uri_tests[] = { {URLZONE_INVALID,E_NOTIMPL,FALSE} } }, - { "news:test.tes<|>t.com", 0, S_OK, FALSE, + { "news:test.tes<|>t.com", 0, S_OK, FALSE, 0, { {"news:test.tes%3C%7C%3Et.com",S_OK,FALSE}, {"",S_FALSE,FALSE}, @@ -2695,7 +2696,7 @@ static const uri_properties uri_tests[] = { } }, /* Don't encode forbidden characters. */ - { "news:test.tes<|>t.com", Uri_CREATE_NO_ENCODE_FORBIDDEN_CHARACTERS, S_OK, FALSE, + { "news:test.tes<|>t.com", Uri_CREATE_NO_ENCODE_FORBIDDEN_CHARACTERS, S_OK, FALSE, 0, { {"news:test.tes<|>t.com",S_OK,FALSE}, {"",S_FALSE,FALSE}, @@ -2721,7 +2722,7 @@ static const uri_properties uri_tests[] = { } }, /* Forbidden characters aren't encoded for unknown, opaque URIs. */ - { "urn:test.tes<|>t.com", 0, S_OK, FALSE, + { "urn:test.tes<|>t.com", 0, S_OK, FALSE, 0, { {"urn:test.tes<|>t.com",S_OK,FALSE}, {"",S_FALSE,FALSE}, @@ -2747,7 +2748,7 @@ static const uri_properties uri_tests[] = { } }, /* Percent encoded unreserved characters are decoded for known opaque URIs. */ - { "news:test.%74%65%73%74.com", 0, S_OK, FALSE, + { "news:test.%74%65%73%74.com", 0, S_OK, FALSE, 0, { {"news:test.test.com",S_OK,FALSE}, {"",S_FALSE,FALSE}, @@ -2773,7 +2774,7 @@ static const uri_properties uri_tests[] = { } }, /* Percent encoded characters are still decoded for known scheme types. */ - { "news:test.%74%65%73%74.com", Uri_CREATE_NO_CANONICALIZE, S_OK, FALSE, + { "news:test.%74%65%73%74.com", Uri_CREATE_NO_CANONICALIZE, S_OK, FALSE, 0, { {"news:test.test.com",S_OK,FALSE}, {"",S_FALSE,FALSE}, @@ -2799,7 +2800,7 @@ static const uri_properties uri_tests[] = { } }, /* Percent encoded characters aren't decoded for unknown scheme types. */ - { "urn:test.%74%65%73%74.com", 0, S_OK, FALSE, + { "urn:test.%74%65%73%74.com", 0, S_OK, FALSE, 0, { {"urn:test.%74%65%73%74.com",S_OK,FALSE}, {"",S_FALSE,FALSE}, @@ -2825,7 +2826,7 @@ static const uri_properties uri_tests[] = { } }, /* Unknown scheme types can have invalid % encoded data in query string. */ - { "zip://www.winehq.org/tests/..?query=%xx&return=y", 0, S_OK, FALSE, + { "zip://www.winehq.org/tests/..?query=%xx&return=y", 0, S_OK, FALSE, 0, { {"zip://www.winehq.org/?query=%xx&return=y",S_OK,FALSE}, {"www.winehq.org",S_OK,FALSE}, @@ -2851,7 +2852,7 @@ static const uri_properties uri_tests[] = { } }, /* Known scheme types can have invalid % encoded data with the right flags. */ - { "http://www.winehq.org/tests/..?query=%xx&return=y", Uri_CREATE_NO_DECODE_EXTRA_INFO, S_OK, FALSE, + { "http://www.winehq.org/tests/..?query=%xx&return=y", Uri_CREATE_NO_DECODE_EXTRA_INFO, S_OK, FALSE, 0, { {"http://www.winehq.org/?query=%xx&return=y%22,S_OK,FALSE%7D, {"www.winehq.org",S_OK,FALSE}, @@ -2877,7 +2878,7 @@ static const uri_properties uri_tests[] = { } }, /* Forbidden characters in query aren't percent encoded for known scheme types with this flag. */ - { "http://www.winehq.org/tests/..?query=<|>&return=y", Uri_CREATE_NO_DECODE_EXTRA_INFO, S_OK, FALSE, + { "http://www.winehq.org/tests/..?query=<|>&return=y", Uri_CREATE_NO_DECODE_EXTRA_INFO, S_OK, FALSE, 0, { {"http://www.winehq.org/?query=<|>&return=y",S_OK,FALSE}, {"www.winehq.org",S_OK,FALSE}, @@ -2903,7 +2904,7 @@ static const uri_properties uri_tests[] = { } }, /* Forbidden characters in query aren't percent encoded for known scheme types with this flag. */ - { "http://www.winehq.org/tests/..?query=<|>&return=y", Uri_CREATE_NO_ENCODE_FORBIDDEN_CHARACTERS, S_OK, FALSE, + { "http://www.winehq.org/tests/..?query=<|>&return=y", Uri_CREATE_NO_ENCODE_FORBIDDEN_CHARACTERS, S_OK, FALSE, 0, { {"http://www.winehq.org/?query=<|>&return=y",S_OK,FALSE}, {"www.winehq.org",S_OK,FALSE}, @@ -2929,7 +2930,7 @@ static const uri_properties uri_tests[] = { } }, /* Forbidden characters are encoded for known scheme types. */ - { "http://www.winehq.org/tests/..?query=<|>&return=y", 0, S_OK, FALSE, + { "http://www.winehq.org/tests/..?query=<|>&return=y", 0, S_OK, FALSE, 0, { {"http://www.winehq.org/?query=%3C%7C%3E&return=y%22,S_OK,FALSE%7D, {"www.winehq.org",S_OK,FALSE}, @@ -2955,7 +2956,7 @@ static const uri_properties uri_tests[] = { } }, /* Forbidden characters are not encoded for unknown scheme types. */ - { "zip://www.winehq.org/tests/..?query=<|>&return=y", 0, S_OK, FALSE, + { "zip://www.winehq.org/tests/..?query=<|>&return=y", 0, S_OK, FALSE, 0, { {"zip://www.winehq.org/?query=<|>&return=y",S_OK,FALSE}, {"www.winehq.org",S_OK,FALSE}, @@ -2981,7 +2982,7 @@ static const uri_properties uri_tests[] = { } }, /* Percent encoded, unreserved characters are decoded for known scheme types. */ - { "http://www.winehq.org/tests/..?query=%30%31&return=y", 0, S_OK, FALSE, + { "http://www.winehq.org/tests/..?query=%30%31&return=y", 0, S_OK, FALSE, 0, { {"http://www.winehq.org/?query=01&return=y%22,S_OK,FALSE%7D, {"www.winehq.org",S_OK,FALSE}, @@ -3007,7 +3008,7 @@ static const uri_properties uri_tests[] = { } }, /* Percent encoded, unreserved characters aren't decoded for unknown scheme types. */ - { "zip://www.winehq.org/tests/..?query=%30%31&return=y", 0, S_OK, FALSE, + { "zip://www.winehq.org/tests/..?query=%30%31&return=y", 0, S_OK, FALSE, 0, { {"zip://www.winehq.org/?query=%30%31&return=y",S_OK,FALSE}, {"www.winehq.org",S_OK,FALSE}, @@ -3033,7 +3034,7 @@ static const uri_properties uri_tests[] = { } }, /* Percent encoded characters aren't decoded when NO_DECODE_EXTRA_INFO is set. */ - { "http://www.winehq.org/tests/..?query=%30%31&return=y", Uri_CREATE_NO_DECODE_EXTRA_INFO, S_OK, FALSE, + { "http://www.winehq.org/tests/..?query=%30%31&return=y", Uri_CREATE_NO_DECODE_EXTRA_INFO, S_OK, FALSE, 0, { {"http://www.winehq.org/?query=%30%31&return=y%22,S_OK,FALSE%7D, {"www.winehq.org",S_OK,FALSE}, @@ -3058,7 +3059,7 @@ static const uri_properties uri_tests[] = { {URLZONE_INVALID,E_NOTIMPL,FALSE}, } }, - { "http://www.winehq.org?query=12&return=y", Uri_CREATE_NO_CANONICALIZE, S_OK, FALSE, + { "http://www.winehq.org?query=12&return=y", Uri_CREATE_NO_CANONICALIZE, S_OK, FALSE, 0, { {"http://www.winehq.org?query=12&return=y%22,S_OK,FALSE%7D, {"www.winehq.org",S_OK,FALSE}, @@ -3084,7 +3085,7 @@ static const uri_properties uri_tests[] = { } }, /* Unknown scheme types can have invalid % encoded data in fragments. */ - { "zip://www.winehq.org/tests/#Te%xx", 0, S_OK, FALSE, + { "zip://www.winehq.org/tests/#Te%xx", 0, S_OK, FALSE, 0, { {"zip://www.winehq.org/tests/#Te%xx",S_OK,FALSE}, {"www.winehq.org",S_OK,FALSE}, @@ -3110,7 +3111,7 @@ static const uri_properties uri_tests[] = { } }, /* Forbidden characters in fragment aren't encoded for unknown schemes. */ - { "zip://www.winehq.org/tests/#Te<|>", 0, S_OK, FALSE, + { "zip://www.winehq.org/tests/#Te<|>", 0, S_OK, FALSE, 0, { {"zip://www.winehq.org/tests/#Te<|>",S_OK,FALSE}, {"www.winehq.org",S_OK,FALSE}, @@ -3136,7 +3137,7 @@ static const uri_properties uri_tests[] = { } }, /* Forbidden characters in the fragment are percent encoded for known schemes. */ - { "http://www.winehq.org/tests/#Te<|>", 0, S_OK, FALSE, + { "http://www.winehq.org/tests/#Te<|>", 0, S_OK, FALSE, 0, { {"http://www.winehq.org/tests/#Te%3C%7C%3E%22,S_OK,FALSE%7D, {"www.winehq.org",S_OK,FALSE}, @@ -3162,7 +3163,7 @@ static const uri_properties uri_tests[] = { } }, /* Forbidden characters aren't encoded in the fragment with this flag. */ - { "http://www.winehq.org/tests/#Te<|>", Uri_CREATE_NO_DECODE_EXTRA_INFO, S_OK, FALSE, + { "http://www.winehq.org/tests/#Te<|>", Uri_CREATE_NO_DECODE_EXTRA_INFO, S_OK, FALSE, 0, { {"http://www.winehq.org/tests/#Te<|>",S_OK,FALSE}, {"www.winehq.org",S_OK,FALSE}, @@ -3188,7 +3189,7 @@ static const uri_properties uri_tests[] = { } }, /* Forbidden characters aren't encoded in the fragment with this flag. */ - { "http://www.winehq.org/tests/#Te<|>", Uri_CREATE_NO_ENCODE_FORBIDDEN_CHARACTERS, S_OK, FALSE, + { "http://www.winehq.org/tests/#Te<|>", Uri_CREATE_NO_ENCODE_FORBIDDEN_CHARACTERS, S_OK, FALSE, 0, { {"http://www.winehq.org/tests/#Te<|>",S_OK,FALSE}, {"www.winehq.org",S_OK,FALSE}, @@ -3214,7 +3215,7 @@ static const uri_properties uri_tests[] = { } }, /* Percent encoded, unreserved characters aren't decoded for known scheme types. */ - { "zip://www.winehq.org/tests/#Te%30%31%32", 0, S_OK, FALSE, + { "zip://www.winehq.org/tests/#Te%30%31%32", 0, S_OK, FALSE, 0, { {"zip://www.winehq.org/tests/#Te%30%31%32",S_OK,FALSE}, {"www.winehq.org",S_OK,FALSE}, @@ -3240,7 +3241,7 @@ static const uri_properties uri_tests[] = { } }, /* Percent encoded, unreserved characters are decoded for known schemes. */ - { "http://www.winehq.org/tests/#Te%30%31%32", 0, S_OK, FALSE, + { "http://www.winehq.org/tests/#Te%30%31%32", 0, S_OK, FALSE, 0, { {"http://www.winehq.org/tests/#Te012%22,S_OK,FALSE%7D, {"www.winehq.org",S_OK,FALSE}, @@ -3266,7 +3267,7 @@ static const uri_properties uri_tests[] = { } }, /* Percent encoded, unreserved characters are decoded even if NO_CANONICALIZE is set. */ - { "http://www.winehq.org/tests/#Te%30%31%32", Uri_CREATE_NO_CANONICALIZE, S_OK, FALSE, + { "http://www.winehq.org/tests/#Te%30%31%32", Uri_CREATE_NO_CANONICALIZE, S_OK, FALSE, 0, { {"http://www.winehq.org/tests/#Te012%22,S_OK,FALSE%7D, {"www.winehq.org",S_OK,FALSE}, @@ -3292,7 +3293,7 @@ static const uri_properties uri_tests[] = { } }, /* Percent encoded, unreserved characters aren't decoded when NO_DECODE_EXTRA is set. */ - { "http://www.winehq.org/tests/#Te%30%31%32", Uri_CREATE_NO_DECODE_EXTRA_INFO, S_OK, FALSE, + { "http://www.winehq.org/tests/#Te%30%31%32", Uri_CREATE_NO_DECODE_EXTRA_INFO, S_OK, FALSE, 0, { {"http://www.winehq.org/tests/#Te%30%31%32%22,S_OK,FALSE%7D, {"www.winehq.org",S_OK,FALSE}, @@ -3318,7 +3319,7 @@ static const uri_properties uri_tests[] = { } }, /* Leading/Trailing whitespace is removed. */ - { " http://google.com/ ", 0, S_OK, FALSE, + { " http://google.com/ ", 0, S_OK, FALSE, 0, { {"http://google.com/%22,S_OK,FALSE%7D, {"google.com",S_OK,FALSE}, @@ -3343,7 +3344,7 @@ static const uri_properties uri_tests[] = { {URLZONE_INVALID,E_NOTIMPL,FALSE} } }, - { "\t\t\r\nhttp\n://g\noogle.co\rm/\n\n\n", 0, S_OK, FALSE, + { "\t\t\r\nhttp\n://g\noogle.co\rm/\n\n\n", 0, S_OK, FALSE, 0, { {"http://google.com/%22,S_OK,FALSE%7D, {"google.com",S_OK,FALSE}, @@ -3368,7 +3369,7 @@ static const uri_properties uri_tests[] = { {URLZONE_INVALID,E_NOTIMPL,FALSE} } }, - { "http://g%5Cnoogle.co%5Crm/%5Cn%5Cn%5Cn", Uri_CREATE_NO_PRE_PROCESS_HTML_URI, S_OK, FALSE, + { "http://g%5Cnoogle.co%5Crm/%5Cn%5Cn%5Cn", Uri_CREATE_NO_PRE_PROCESS_HTML_URI, S_OK, FALSE, 0, { {"http://g%0aoogle.co%0dm/%0A%0A%0A%22,S_OK,FALSE%7D, {"g%0aoogle.co%0dm",S_OK,FALSE}, @@ -3393,7 +3394,7 @@ static const uri_properties uri_tests[] = { {URLZONE_INVALID,E_NOTIMPL,FALSE} } }, - { "zip://g\noogle.co\rm/\n\n\n", Uri_CREATE_NO_PRE_PROCESS_HTML_URI, S_OK, FALSE, + { "zip://g\noogle.co\rm/\n\n\n", Uri_CREATE_NO_PRE_PROCESS_HTML_URI, S_OK, FALSE, 0, { {"zip://g\noogle.co\rm/\n\n\n",S_OK,FALSE}, {"g\noogle.co\rm",S_OK,FALSE}, @@ -3421,7 +3422,7 @@ static const uri_properties uri_tests[] = { /* Since file URLs are usually hierarchical, it returns an empty string * for the absolute URI property since it was declared as an opaque URI. */ - { "file:index.html", 0, S_OK, FALSE, + { "file:index.html", 0, S_OK, FALSE, 0, { {"",S_FALSE,FALSE}, {"",S_FALSE,FALSE}, @@ -3447,7 +3448,7 @@ static const uri_properties uri_tests[] = { } }, /* Doesn't have an absolute since it's opaque, but gets it port set. */ - { "http:test.com/index.html", 0, S_OK, FALSE, + { "http:test.com/index.html", 0, S_OK, FALSE, 0, { {"",S_FALSE,FALSE}, {"",S_FALSE,FALSE}, @@ -3472,7 +3473,7 @@ static const uri_properties uri_tests[] = { {URLZONE_INVALID,E_NOTIMPL,FALSE} } }, - { "ftp:test.com/index.html", 0, S_OK, FALSE, + { "ftp:test.com/index.html", 0, S_OK, FALSE, 0, { {"",S_FALSE,FALSE}, {"",S_FALSE,FALSE}, @@ -3497,7 +3498,7 @@ static const uri_properties uri_tests[] = { {URLZONE_INVALID,E_NOTIMPL,FALSE} } }, - { "file://C|/test.mp3", 0, S_OK, FALSE, + { "file://C|/test.mp3", 0, S_OK, FALSE, 0, { {"file:///C:/test.mp3",S_OK,FALSE}, {"",S_FALSE,FALSE}, @@ -3522,7 +3523,7 @@ static const uri_properties uri_tests[] = { {URLZONE_INVALID,E_NOTIMPL,FALSE} } }, - { "file:///C|/test.mp3", 0, S_OK, FALSE, + { "file:///C|/test.mp3", 0, S_OK, FALSE, 0, { {"file:///C:/test.mp3",S_OK,FALSE}, {"",S_FALSE,FALSE}, @@ -3550,7 +3551,7 @@ static const uri_properties uri_tests[] = { /* Extra '/' isn't added before "c:" since USE_DOS_PATH is set and '/' are converted * to '\'. */ - { "file://c:/dir/index.html", Uri_CREATE_FILE_USE_DOS_PATH, S_OK, FALSE, + { "file://c:/dir/index.html", Uri_CREATE_FILE_USE_DOS_PATH, S_OK, FALSE, 0, { {"file://c:\dir\index.html",S_OK,FALSE}, {"",S_FALSE,FALSE}, @@ -3576,7 +3577,7 @@ static const uri_properties uri_tests[] = { } }, /* Extra '/' after "file://" is removed. */ - { "file:///c:/dir/index.html", Uri_CREATE_FILE_USE_DOS_PATH, S_OK, FALSE, + { "file:///c:/dir/index.html", Uri_CREATE_FILE_USE_DOS_PATH, S_OK, FALSE, 0, { {"file://c:\dir\index.html",S_OK,FALSE}, {"",S_FALSE,FALSE}, @@ -3602,7 +3603,7 @@ static const uri_properties uri_tests[] = { } }, /* Allow more characters when Uri_CREATE_FILE_USE_DOS_PATH is specified */ - { "file:///c:/dir\%%61%20%5Fname/file%2A.html", Uri_CREATE_FILE_USE_DOS_PATH, S_OK, FALSE, + { "file:///c:/dir\%%61%20%5Fname/file%2A.html", Uri_CREATE_FILE_USE_DOS_PATH, S_OK, FALSE, 0, { {"file://c:\dir\%a _name\file*.html",S_OK,FALSE}, {"",S_FALSE,FALSE}, @@ -3627,7 +3628,7 @@ static const uri_properties uri_tests[] = { {URLZONE_INVALID,E_NOTIMPL,FALSE} } }, - { "file://c|/dir\index.html", Uri_CREATE_FILE_USE_DOS_PATH, S_OK, FALSE, + { "file://c|/dir\index.html", Uri_CREATE_FILE_USE_DOS_PATH, S_OK, FALSE, 0, { {"file://c:\dir\index.html",S_OK,FALSE}, {"",S_FALSE,FALSE}, @@ -3653,7 +3654,7 @@ static const uri_properties uri_tests[] = { } }, /* The backslashes after the scheme name are converted to forward slashes. */ - { "file:\\c:\dir\index.html", Uri_CREATE_FILE_USE_DOS_PATH, S_OK, FALSE, + { "file:\\c:\dir\index.html", Uri_CREATE_FILE_USE_DOS_PATH, S_OK, FALSE, 0, { {"file://c:\dir\index.html",S_OK,FALSE}, {"",S_FALSE,FALSE}, @@ -3678,7 +3679,7 @@ static const uri_properties uri_tests[] = { {URLZONE_INVALID,E_NOTIMPL,FALSE} } }, - { "file:\\c:/dir/index.html", 0, S_OK, FALSE, + { "file:\\c:/dir/index.html", 0, S_OK, FALSE, 0, { {"file:///c:/dir/index.html",S_OK,FALSE}, {"",S_FALSE,FALSE}, @@ -3703,7 +3704,7 @@ static const uri_properties uri_tests[] = { {URLZONE_INVALID,E_NOTIMPL,FALSE} } }, - { "http:\\google.com", 0, S_OK, FALSE, + { "http:\\google.com", 0, S_OK, FALSE, 0, { {"http://google.com/%22,S_OK,FALSE%7D, {"google.com",S_OK,FALSE}, @@ -3729,7 +3730,7 @@ static const uri_properties uri_tests[] = { } }, /* the "\\" aren't converted to "//" for unknown scheme types and it's considered opaque. */ - { "zip:\\google.com", 0, S_OK, FALSE, + { "zip:\\google.com", 0, S_OK, FALSE, 0, { {"zip:\\google.com",S_OK,FALSE}, {"",S_FALSE,FALSE}, @@ -3755,7 +3756,7 @@ static const uri_properties uri_tests[] = { } }, /* Dot segments aren't removed. */ - { "file://c:\dir\../..\./index.html", Uri_CREATE_FILE_USE_DOS_PATH, S_OK, FALSE, + { "file://c:\dir\../..\./index.html", Uri_CREATE_FILE_USE_DOS_PATH, S_OK, FALSE, 0, { {"file://c:\dir\..\..\.\index.html",S_OK,FALSE}, {"",S_FALSE,FALSE}, @@ -3781,7 +3782,7 @@ static const uri_properties uri_tests[] = { } }, /* Forbidden characters aren't percent encoded. */ - { "file://c:\dir\i^|ndex.html", Uri_CREATE_FILE_USE_DOS_PATH, S_OK, FALSE, + { "file://c:\dir\i^|ndex.html", Uri_CREATE_FILE_USE_DOS_PATH, S_OK, FALSE, 0, { {"file://c:\dir\i^|ndex.html",S_OK,FALSE}, {"",S_FALSE,FALSE}, @@ -3807,7 +3808,7 @@ static const uri_properties uri_tests[] = { } }, /* The '' are still converted to '/' even though it's an opaque file URI. */ - { "file:c:\dir\../..\index.html", 0, S_OK, FALSE, + { "file:c:\dir\../..\index.html", 0, S_OK, FALSE, 0, { {"",S_FALSE,FALSE}, {"",S_FALSE,FALSE}, @@ -3833,7 +3834,7 @@ static const uri_properties uri_tests[] = { } }, /* '/' are still converted to '' even though it's an opaque URI. */ - { "file:c:/dir\../..\index.html", Uri_CREATE_FILE_USE_DOS_PATH, S_OK, FALSE, + { "file:c:/dir\../..\index.html", Uri_CREATE_FILE_USE_DOS_PATH, S_OK, FALSE, 0, { {"",S_FALSE,FALSE}, {"",S_FALSE,FALSE}, @@ -3859,7 +3860,7 @@ static const uri_properties uri_tests[] = { } }, /* Forbidden characters aren't percent encoded. */ - { "file:c:\in^|dex.html", Uri_CREATE_FILE_USE_DOS_PATH, S_OK, FALSE, + { "file:c:\in^|dex.html", Uri_CREATE_FILE_USE_DOS_PATH, S_OK, FALSE, 0, { {"",S_FALSE,FALSE}, {"",S_FALSE,FALSE}, @@ -3887,7 +3888,7 @@ static const uri_properties uri_tests[] = { /* Doesn't have a UserName since the ':' appears at the beginning of the * userinfo section. */ - { "http://:password@gov.uk", 0, S_OK, FALSE, + { "http://:password@gov.uk", 0, S_OK, FALSE, 0, { {"http://:password@gov.uk/%22,S_OK,FALSE%7D, {":password@gov.uk",S_OK,FALSE}, @@ -3913,7 +3914,7 @@ static const uri_properties uri_tests[] = { } }, /* Has a UserName since the userinfo section doesn't contain a password. */ - { "http://@gov.uk", 0, S_OK, FALSE, + { "http://@gov.uk", 0, S_OK, FALSE, 0, { {"http://gov.uk/%22,S_OK,FALSE,%22http://@gov.uk/%22%7D, {"@gov.uk",S_OK,FALSE}, @@ -3939,7 +3940,7 @@ static const uri_properties uri_tests[] = { } }, /* ":@" not included in the absolute URI. */ - { "http://:@gov.uk", 0, S_OK, FALSE, + { "http://:@gov.uk", 0, S_OK, FALSE, 0, { {"http://gov.uk/%22,S_OK,FALSE,%22http://:@gov.uk/%22%7D, {":@gov.uk",S_OK,FALSE}, @@ -3965,7 +3966,7 @@ static const uri_properties uri_tests[] = { } }, /* '@' is included because it's an unknown scheme type. */ - { "zip://@gov.uk", 0, S_OK, FALSE, + { "zip://@gov.uk", 0, S_OK, FALSE, 0, { {"zip://@gov.uk/",S_OK,FALSE}, {"@gov.uk",S_OK,FALSE}, @@ -3991,7 +3992,7 @@ static const uri_properties uri_tests[] = { } }, /* ":@" are included because it's an unknown scheme type. */ - { "zip://:@gov.uk", 0, S_OK, FALSE, + { "zip://:@gov.uk", 0, S_OK, FALSE, 0, { {"zip://:@gov.uk/",S_OK,FALSE}, {":@gov.uk",S_OK,FALSE}, @@ -4016,7 +4017,7 @@ static const uri_properties uri_tests[] = { {URLZONE_INVALID,E_NOTIMPL,FALSE} } }, - { "about:blank", 0, S_OK, FALSE, + { "about:blank", 0, S_OK, FALSE, 0, { {"about:blank",S_OK,FALSE}, {"",S_FALSE,FALSE}, @@ -4041,7 +4042,7 @@ static const uri_properties uri_tests[] = { {URLZONE_INVALID,E_NOTIMPL,FALSE} } }, - { "mk:@MSITStore:C:\Program Files/AutoCAD 2008\Help/acad_acg.chm::/WSfacf1429558a55de1a7524c1004e616f8b-322b.htm",0,S_OK,FALSE, + { "mk:@MSITStore:C:\Program Files/AutoCAD 2008\Help/acad_acg.chm::/WSfacf1429558a55de1a7524c1004e616f8b-322b.htm",0,S_OK,FALSE, 0, { {"mk:@MSITStore:C:\Program%20Files/AutoCAD%202008\Help/acad_acg.chm::/WSfacf1429558a55de1a7524c1004e616f8b-322b.htm",S_OK,FALSE}, {"",S_FALSE,FALSE}, @@ -4066,7 +4067,7 @@ static const uri_properties uri_tests[] = { {URLZONE_INVALID,E_NOTIMPL,FALSE} } }, - { "mk:@MSITStore:Z:\home\test\chm\silqhelp.chm::/thesilqquickstartguide.htm",0,S_OK,FALSE, + { "mk:@MSITStore:Z:\home\test\chm\silqhelp.chm::/thesilqquickstartguide.htm",0,S_OK,FALSE, 0, { {"mk:@MSITStore:Z:\home\test\chm\silqhelp.chm::/thesilqquickstartguide.htm",S_OK,FALSE}, {"",S_FALSE,FALSE}, @@ -4092,7 +4093,7 @@ static const uri_properties uri_tests[] = { } }, /* Two '' are added to the URI when USE_DOS_PATH is set, and it's a UNC path. */ - { "file://server/dir/index.html", Uri_CREATE_FILE_USE_DOS_PATH, S_OK, FALSE, + { "file://server/dir/index.html", Uri_CREATE_FILE_USE_DOS_PATH, S_OK, FALSE, 0, { {"file://\\server\dir\index.html",S_OK,FALSE}, {"server",S_OK,FALSE}, @@ -4120,7 +4121,7 @@ static const uri_properties uri_tests[] = { /* When CreateUri generates an IUri, it still displays the default port in the * authority. */ - { "http://google.com:80/", Uri_CREATE_NO_CANONICALIZE, S_OK, FALSE, + { "http://google.com:80/", Uri_CREATE_NO_CANONICALIZE, S_OK, FALSE, 0, { {"http://google.com:80/%22,S_OK,FALSE%7D, {"google.com:80",S_OK,FALSE}, @@ -4146,7 +4147,7 @@ static const uri_properties uri_tests[] = { } }, /* For res URIs the host is everything up until the first '/'. */ - { "res://C:\dir\file.exe/DATA/test.html", 0, S_OK, FALSE, + { "res://C:\dir\file.exe/DATA/test.html", 0, S_OK, FALSE, 0, { {"res://C:\dir\file.exe/DATA/test.html",S_OK,FALSE}, {"C:\dir\file.exe",S_OK,FALSE}, @@ -4172,7 +4173,7 @@ static const uri_properties uri_tests[] = { } }, /* Res URI can contain a '|' in the host name. */ - { "res://c:\di|r\file.exe/test", 0, S_OK, FALSE, + { "res://c:\di|r\file.exe/test", 0, S_OK, FALSE, 0, { {"res://c:\di|r\file.exe/test",S_OK,FALSE}, {"c:\di|r\file.exe",S_OK,FALSE}, @@ -4198,7 +4199,7 @@ static const uri_properties uri_tests[] = { } }, /* Res URIs can have invalid percent encoded values. */ - { "res://c:\dir%xx\file.exe/test", 0, S_OK, FALSE, + { "res://c:\dir%xx\file.exe/test", 0, S_OK, FALSE, 0, { {"res://c:\dir%xx\file.exe/test",S_OK,FALSE}, {"c:\dir%xx\file.exe",S_OK,FALSE}, @@ -4224,7 +4225,7 @@ static const uri_properties uri_tests[] = { } }, /* Res doesn't get forbidden characters percent encoded in its path. */ - { "res://c:\test/tes<|>t", 0, S_OK, FALSE, + { "res://c:\test/tes<|>t", 0, S_OK, FALSE, 0, { {"res://c:\test/tes<|>t",S_OK,FALSE}, {"c:\test",S_OK,FALSE}, @@ -4249,7 +4250,7 @@ static const uri_properties uri_tests[] = { {URLZONE_INVALID,E_NOTIMPL,FALSE} } }, - { "mk:@MSITStore:Z:\dir\test.chm::/html/../images/xxx.jpg", 0, S_OK, FALSE, + { "mk:@MSITStore:Z:\dir\test.chm::/html/../images/xxx.jpg", 0, S_OK, FALSE, 0, { {"mk:@MSITStore:Z:\dir\test.chm::/images/xxx.jpg",S_OK,FALSE}, {"",S_FALSE,FALSE}, @@ -4274,7 +4275,7 @@ static const uri_properties uri_tests[] = { {URLZONE_INVALID,E_NOTIMPL,FALSE} } }, - { "mk:@MSITStore:Z:\dir\test.chm::/html/../images/xxx.jpg", Uri_CREATE_NO_CANONICALIZE, S_OK, FALSE, + { "mk:@MSITStore:Z:\dir\test.chm::/html/../images/xxx.jpg", Uri_CREATE_NO_CANONICALIZE, S_OK, FALSE, 0, { {"mk:@MSITStore:Z:\dir\test.chm::/html/../images/xxx.jpg",S_OK,FALSE}, {"",S_FALSE,FALSE}, @@ -4299,7 +4300,7 @@ static const uri_properties uri_tests[] = { {URLZONE_INVALID,E_NOTIMPL,FALSE} } }, - { "xx:@MSITStore:Z:\dir\test.chm::/html/../images/xxx.jpg", 0, S_OK, FALSE, + { "xx:@MSITStore:Z:\dir\test.chm::/html/../images/xxx.jpg", 0, S_OK, FALSE, 0, { {"xx:@MSITStore:Z:\dir\test.chm::/html/../images/xxx.jpg",S_OK,FALSE}, {"",S_FALSE,FALSE}, @@ -4324,7 +4325,7 @@ static const uri_properties uri_tests[] = { {URLZONE_INVALID,E_NOTIMPL,FALSE} } }, - { "mk:@MSITStore:Z:\dir\test.chm::/html/../../images/xxx.jpg", 0, S_OK, FALSE, + { "mk:@MSITStore:Z:\dir\test.chm::/html/../../images/xxx.jpg", 0, S_OK, FALSE, 0, { {"mk:@MSITStore:Z:\dir\images/xxx.jpg",S_OK,FALSE}, {"",S_FALSE,FALSE}, @@ -4349,7 +4350,7 @@ static const uri_properties uri_tests[] = { {URLZONE_INVALID,E_NOTIMPL,FALSE} } }, - { "mk:@MSITStore:Z:\dir\dir2\..\test.chm::/html/../../images/xxx.jpg", 0, S_OK, FALSE, + { "mk:@MSITStore:Z:\dir\dir2\..\test.chm::/html/../../images/xxx.jpg", 0, S_OK, FALSE, 0, { {"mk:@MSITStore:Z:\dir\images/xxx.jpg",S_OK,FALSE}, {"",S_FALSE,FALSE}, @@ -4374,7 +4375,7 @@ static const uri_properties uri_tests[] = { {URLZONE_INVALID,E_NOTIMPL,FALSE} } }, - { "mk:@MSITStore:Z:\dir\test.chm::/html/../../../../images/xxx.jpg", 0, S_OK, FALSE, + { "mk:@MSITStore:Z:\dir\test.chm::/html/../../../../images/xxx.jpg", 0, S_OK, FALSE, 0, { {"mk:images/xxx.jpg",S_OK,FALSE}, {"",S_FALSE,FALSE}, @@ -4399,7 +4400,7 @@ static const uri_properties uri_tests[] = { {URLZONE_INVALID,E_NOTIMPL,FALSE} } }, - { "", Uri_CREATE_ALLOW_RELATIVE, S_OK, FALSE, + { "", Uri_CREATE_ALLOW_RELATIVE, S_OK, FALSE, 0, { {"",S_OK,FALSE}, {"",S_FALSE,FALSE}, @@ -4424,7 +4425,7 @@ static const uri_properties uri_tests[] = { {URLZONE_INVALID,E_NOTIMPL,FALSE} } }, - { " \t ", Uri_CREATE_ALLOW_RELATIVE, S_OK, FALSE, + { " \t ", Uri_CREATE_ALLOW_RELATIVE, S_OK, FALSE, 0, { {"",S_OK,FALSE}, {"",S_FALSE,FALSE}, @@ -4449,7 +4450,7 @@ static const uri_properties uri_tests[] = { {URLZONE_INVALID,E_NOTIMPL,FALSE} } }, - { "javascript:void", 0, S_OK, FALSE, + { "javascript:void", 0, S_OK, FALSE, 0, { {"javascript:void",S_OK}, {"",S_FALSE}, @@ -4474,7 +4475,7 @@ static const uri_properties uri_tests[] = { {URLZONE_INVALID,E_NOTIMPL} } }, - { "javascript://undefined", 0, S_OK, FALSE, + { "javascript://undefined", 0, S_OK, FALSE, 0, { {"javascript://undefined",S_OK}, {"",S_FALSE}, @@ -4499,7 +4500,7 @@ static const uri_properties uri_tests[] = { {URLZONE_INVALID,E_NOTIMPL} } }, - { "JavaSCript:escape('/\?#?')", 0, S_OK, FALSE, + { "JavaSCript:escape('/\?#?')", 0, S_OK, FALSE, 0, { {"javascript:escape('/\?#?')",S_OK}, {"",S_FALSE}, @@ -4524,7 +4525,7 @@ static const uri_properties uri_tests[] = { {URLZONE_INVALID,E_NOTIMPL} } }, - { "*://google.com", 0, S_OK, FALSE, + { "*://google.com", 0, S_OK, FALSE, 0, { {"*:google.com/",S_OK,FALSE}, {"google.com",S_OK}, @@ -4549,7 +4550,7 @@ static const uri_properties uri_tests[] = { {URLZONE_INVALID,E_NOTIMPL,FALSE} } }, - { "mk:@MSITSTORE:C:\Some\Bogus\Path.chm::/subdir/file.txt",0,S_OK,FALSE, + { "mk:@MSITSTORE:C:\Some\Bogus\Path.chm::/subdir/file.txt", 0, S_OK, FALSE, 0, { {"mk:@MSITSTORE:C:\Some\Bogus\Path.chm::/subdir/file.txt",S_OK}, {"",S_FALSE}, @@ -4574,7 +4575,7 @@ static const uri_properties uri_tests[] = { {URLZONE_INVALID,E_NOTIMPL} } }, - { "gopher://test.winehq.org:151/file.txt",0,S_OK,FALSE, + { "gopher://test.winehq.org:151/file.txt", 0, S_OK, FALSE, 0, { {"gopher://test.winehq.org:151/file.txt",S_OK}, {"test.winehq.org:151",S_OK}, @@ -4599,7 +4600,7 @@ static const uri_properties uri_tests[] = { {URLZONE_INVALID,E_NOTIMPL} } }, - { "//host.com/path/file.txt?query", Uri_CREATE_ALLOW_RELATIVE, S_OK, FALSE, + { "//host.com/path/file.txt?query", Uri_CREATE_ALLOW_RELATIVE, S_OK, FALSE, 0, { {"//host.com/path/file.txt?query",S_OK}, {"host.com",S_OK}, @@ -4624,7 +4625,7 @@ static const uri_properties uri_tests[] = { {URLZONE_INVALID,E_NOTIMPL} } }, - { "//host/path/file.txt?query", Uri_CREATE_ALLOW_RELATIVE, S_OK, FALSE, + { "//host/path/file.txt?query", Uri_CREATE_ALLOW_RELATIVE, S_OK, FALSE, 0, { {"//host/path/file.txt?query",S_OK}, {"host",S_OK}, @@ -4649,7 +4650,7 @@ static const uri_properties uri_tests[] = { {URLZONE_INVALID,E_NOTIMPL} } }, - { "//host", Uri_CREATE_ALLOW_RELATIVE, S_OK, FALSE, + { "//host", Uri_CREATE_ALLOW_RELATIVE, S_OK, FALSE, 0, { {"//host/",S_OK}, {"host",S_OK}, @@ -4674,7 +4675,7 @@ static const uri_properties uri_tests[] = { {URLZONE_INVALID,E_NOTIMPL} } }, - { "mailto://", Uri_CREATE_NO_CANONICALIZE, S_OK, FALSE, + { "mailto://", Uri_CREATE_NO_CANONICALIZE, S_OK, FALSE, 0, { {"mailto:",S_OK}, {"",S_FALSE}, @@ -4699,7 +4700,7 @@ static const uri_properties uri_tests[] = { {URLZONE_INVALID,E_NOTIMPL} } }, - { "mailto://a@b.com", Uri_CREATE_NO_CANONICALIZE, S_OK, FALSE, + { "mailto://a@b.com", Uri_CREATE_NO_CANONICALIZE, S_OK, FALSE, 0, { {"mailto:a@b.com",S_OK}, {"",S_FALSE}, @@ -4724,7 +4725,7 @@ static const uri_properties uri_tests[] = { {URLZONE_INVALID,E_NOTIMPL} } }, - { "c:\test file.html", Uri_CREATE_FILE_USE_DOS_PATH|Uri_CREATE_ALLOW_IMPLICIT_FILE_SCHEME, S_OK, FALSE, + { "c:\test file.html", Uri_CREATE_FILE_USE_DOS_PATH|Uri_CREATE_ALLOW_IMPLICIT_FILE_SCHEME, S_OK, FALSE, 0, { {"file://c:\test file.html",S_OK,FALSE}, {"",S_FALSE,FALSE}, @@ -4749,7 +4750,7 @@ static const uri_properties uri_tests[] = { {URLZONE_INVALID,E_NOTIMPL,FALSE} } }, - { "c:\test%20file.html", Uri_CREATE_FILE_USE_DOS_PATH|Uri_CREATE_ALLOW_IMPLICIT_FILE_SCHEME, S_OK, FALSE, + { "c:\test%20file.html", Uri_CREATE_FILE_USE_DOS_PATH|Uri_CREATE_ALLOW_IMPLICIT_FILE_SCHEME, S_OK, FALSE, 0, { {"file://c:\test%20file.html",S_OK,FALSE}, {"",S_FALSE,FALSE}, @@ -4774,7 +4775,7 @@ static const uri_properties uri_tests[] = { {URLZONE_INVALID,E_NOTIMPL,FALSE} } }, - { "c:\test file.html", Uri_CREATE_ALLOW_IMPLICIT_FILE_SCHEME, S_OK, FALSE, + { "c:\test file.html", Uri_CREATE_ALLOW_IMPLICIT_FILE_SCHEME, S_OK, FALSE, 0, { {"file:///c:/test%20file.html",S_OK,FALSE}, {"",S_FALSE,FALSE}, @@ -4799,7 +4800,7 @@ static const uri_properties uri_tests[] = { {URLZONE_INVALID,E_NOTIMPL,FALSE} } }, - { "c:\test%20file.html", Uri_CREATE_ALLOW_IMPLICIT_FILE_SCHEME, S_OK, FALSE, + { "c:\test%20file.html", Uri_CREATE_ALLOW_IMPLICIT_FILE_SCHEME, S_OK, FALSE, 0, { {"file:///c:/test%2520file.html",S_OK,FALSE}, {"",S_FALSE,FALSE}, @@ -4826,7 +4827,7 @@ static const uri_properties uri_tests[] = { }, /* Path with Unicode characters. Unicode characters should not be encoded */ {/* "http://127.0.0.1/%E6%B5%8B%E8%AF%95/test.txt" with Chinese in UTF-8 encoding */ - "http://127.0.0.1/%5CxE6%5CxB5%5Cx8B%5CxE8%5CxAF%5Cx95/test.txt", 0, S_OK, FALSE, + "http://127.0.0.1/%5CxE6%5CxB5%5Cx8B%5CxE8%5CxAF%5Cx95/test.txt", 0, S_OK, FALSE, 0, { {"http://127.0.0.1/%5CxE6%5CxB5%5Cx8B%5CxE8%5CxAF%5Cx95/test.txt%22,S_OK,FALSE..., {"127.0.0.1",S_OK,FALSE}, @@ -4851,7 +4852,7 @@ static const uri_properties uri_tests[] = { {URLZONE_INVALID,E_NOTIMPL,FALSE} } }, - { "file:\xE6\xB5\x8B\xE8\xAF\x95.html", 0, S_OK, FALSE, + { "file:\xE6\xB5\x8B\xE8\xAF\x95.html", 0, S_OK, FALSE, 0, { {"",S_FALSE,FALSE}, {"",S_FALSE,FALSE}, @@ -4877,7 +4878,7 @@ static const uri_properties uri_tests[] = { } }, /* Username with Unicode characters. Unicode characters should not be encoded */ - { "ftp://\xE6\xB5\x8B\xE8\xAF\x95:wine@ftp.winehq.org:9999/dir/foobar.txt", 0, S_OK, FALSE, + { "ftp://\xE6\xB5\x8B\xE8\xAF\x95:wine@ftp.winehq.org:9999/dir/foobar.txt", 0, S_OK, FALSE, 0, { {"ftp://\xE6\xB5\x8B\xE8\xAF\x95:wine@ftp.winehq.org:9999/dir/foobar.txt",S_OK,FALSE}, {"\xE6\xB5\x8B\xE8\xAF\x95:wine@ftp.winehq.org:9999",S_OK,FALSE}, @@ -4903,7 +4904,7 @@ static const uri_properties uri_tests[] = { } }, /* Password with Unicode characters. Unicode characters should not be encoded */ - { "ftp://winepass:\xE6\xB5\x8B\xE8\xAF\x95@ftp.winehq.org:9999/dir/foobar.txt", 0, S_OK, FALSE, + { "ftp://winepass:\xE6\xB5\x8B\xE8\xAF\x95@ftp.winehq.org:9999/dir/foobar.txt", 0, S_OK, FALSE, 0, { {"ftp://winepass:\xE6\xB5\x8B\xE8\xAF\x95@ftp.winehq.org:9999/dir/foobar.txt",S_OK,FALSE}, {"winepass:\xE6\xB5\x8B\xE8\xAF\x95@ftp.winehq.org:9999",S_OK,FALSE}, @@ -4929,7 +4930,7 @@ static const uri_properties uri_tests[] = { } }, /* Query with Unicode characters. Unicode characters should not be encoded */ - { "http://www.winehq.org/tests/..?query=%5CxE6%5CxB5%5Cx8B%5CxE8%5CxAF%5Cx95&am...", 0, S_OK, FALSE, + { "http://www.winehq.org/tests/..?query=%5CxE6%5CxB5%5Cx8B%5CxE8%5CxAF%5Cx95&am...", 0, S_OK, FALSE, 0, { {"http://www.winehq.org/?query=%5CxE6%5CxB5%5Cx8B%5CxE8%5CxAF%5Cx95&return..., {"www.winehq.org",S_OK,FALSE}, @@ -4955,7 +4956,7 @@ static const uri_properties uri_tests[] = { } }, /* Fragment with Unicode characters. Unicode characters should not be encoded */ - { "http://www.winehq.org/tests/#%5CxE6%5CxB5%5Cx8B%5CxE8%5CxAF%5Cx95", 0, S_OK, FALSE, + { "http://www.winehq.org/tests/#%5CxE6%5CxB5%5Cx8B%5CxE8%5CxAF%5Cx95", 0, S_OK, FALSE, 0, { {"http://www.winehq.org/tests/#%5CxE6%5CxB5%5Cx8B%5CxE8%5CxAF%5Cx95%22,S_OK,FA..., {"www.winehq.org",S_OK,FALSE}, @@ -4981,7 +4982,7 @@ static const uri_properties uri_tests[] = { } }, /* ZERO WIDTH JOINER as non-printing Unicode characters should not be encoded if not preprocessed. */ - { "file:a\xE2\x80\x8D.html", Uri_CREATE_NO_PRE_PROCESS_HTML_URI, S_OK, FALSE, + { "file:a\xE2\x80\x8D.html", Uri_CREATE_NO_PRE_PROCESS_HTML_URI, S_OK, FALSE, 0, { {"",S_FALSE,FALSE}, {"",S_FALSE,FALSE}, @@ -5007,7 +5008,7 @@ static const uri_properties uri_tests[] = { } }, /* LEFT-TO-RIGHT MARK as non-printing Unicode characters should not be encoded if not preprocessed. */ - { "file:ab\xE2\x80\x8E.html", Uri_CREATE_NO_PRE_PROCESS_HTML_URI, S_OK, FALSE, + { "file:ab\xE2\x80\x8E.html", Uri_CREATE_NO_PRE_PROCESS_HTML_URI, S_OK, FALSE, 0, { {"",S_FALSE,FALSE}, {"",S_FALSE,FALSE}, @@ -5033,7 +5034,7 @@ static const uri_properties uri_tests[] = { } }, /* Invalid Unicode characters should not be filtered */ - { "file:ab\xc3\x28.html", 0, S_OK, FALSE, + { "file:ab\xc3\x28.html", 0, S_OK, FALSE, 0, { {"",S_FALSE,FALSE}, {"",S_FALSE,FALSE}, @@ -5059,7 +5060,7 @@ static const uri_properties uri_tests[] = { } }, /* Make sure % encoded unicode characters are not decoded. */ - { "ftp://%E6%B5%8B%E8%AF%95:%E6%B5%8B%E8%AF%95@ftp.google.com/", 0, S_OK, FALSE, + { "ftp://%E6%B5%8B%E8%AF%95:%E6%B5%8B%E8%AF%95@ftp.google.com/", 0, S_OK, FALSE, 0, { {"ftp://%E6%B5%8B%E8%AF%95:%E6%B5%8B%E8%AF%95@ftp.google.com/",S_OK,FALSE}, {"%E6%B5%8B%E8%AF%95:%E6%B5%8B%E8%AF%95@ftp.google.com",S_OK,FALSE}, @@ -5083,7 +5084,398 @@ static const uri_properties uri_tests[] = { {URL_SCHEME_FTP,S_OK,FALSE}, {URLZONE_INVALID,E_NOTIMPL,FALSE} } - } + }, + /* Hostname is an IDN */ + { + /* "http://%E6%B5%8B%E8%AF%95.org/" with Chinese in UTF-8 encoding */ + "http://%5CxE6%5CxB5%5Cx8B%5CxE8%5CxAF%5Cx95.org/", 0, S_OK, FALSE, 0, + { + {"http://%5CxE6%5CxB5%5Cx8B%5CxE8%5CxAF%5Cx95.org/%22,S_OK,FALSE%7D, + {"\xE6\xB5\x8B\xE8\xAF\x95.org",S_OK,FALSE}, + {"http://xn--0zwm56d.org/%22,S_OK,FALSE,NULL,%22http://%5CxE6%5CxB5%5Cx8B%5CxE..., + {"\xE6\xB5\x8B\xE8\xAF\x95.org",S_OK,FALSE}, + {"",S_FALSE,FALSE}, + {"",S_FALSE,FALSE}, + {"\xE6\xB5\x8B\xE8\xAF\x95.org",S_OK,FALSE}, + {"",S_FALSE,FALSE}, + {"/",S_OK,FALSE}, + {"/",S_OK,FALSE}, + {"",S_FALSE,FALSE}, + {"http://%5CxE6%5CxB5%5Cx8B%5CxE8%5CxAF%5Cx95.org/%22,S_OK,FALSE%7D, + {"http",S_OK,FALSE}, + {"",S_FALSE,FALSE}, + {"",S_FALSE,FALSE} + }, + { + {Uri_HOST_IDN,S_OK,FALSE}, + {80,S_OK,FALSE}, + {URL_SCHEME_HTTP,S_OK,FALSE}, + {URLZONE_INVALID,E_NOTIMPL,FALSE} + } + }, + /* Hostname is an IDN that has percent encoded characters*/ + { + /* "http://%E6%B5%8B%E8%AF%95%74%65%73%74.org/" with Chinese in UTF-8 encoding */ + "http://%5CxE6%5CxB5%5Cx8B%5CxE8%5CxAF%5Cx95%74%65%73%74.org/", 0, S_OK, FALSE, 0, + { + {"http://%5CxE6%5CxB5%5Cx8B%5CxE8%5CxAF%5Cx95test.org/%22,S_OK,FALSE%7D, + {"\xE6\xB5\x8B\xE8\xAF\x95test.org",S_OK,FALSE}, + {"http://xn--test-zx7if72m.org/%22,S_OK,FALSE,NULL,%22http://%5CxE6%5CxB5%5Cx8..., + {"\xE6\xB5\x8B\xE8\xAF\x95test.org",S_OK,FALSE}, + {"",S_FALSE,FALSE}, + {"",S_FALSE,FALSE}, + {"\xE6\xB5\x8B\xE8\xAF\x95test.org",S_OK,FALSE}, + {"",S_FALSE,FALSE}, + {"/",S_OK,FALSE}, + {"/",S_OK,FALSE}, + {"",S_FALSE,FALSE}, + {"http://%5CxE6%5CxB5%5Cx8B%5CxE8%5CxAF%5Cx95%74%65%73%74.org/%22,S_OK,FALSE%7..., + {"http",S_OK,FALSE}, + {"",S_FALSE,FALSE}, + {"",S_FALSE,FALSE} + }, + { + {Uri_HOST_IDN,S_OK,FALSE}, + {80,S_OK,FALSE}, + {URL_SCHEME_HTTP,S_OK,FALSE}, + {URLZONE_INVALID,E_NOTIMPL,FALSE} + } + }, + /* Uri_DISPLAY_NO_FRAGMENT a URI that has no PASSWORD, QUERY, USER_INFO and USER_NAME. + * GetPropertyBSTR() returns E_INVALIDARG for PASSWORD, QUERY, USER_INFO and USER_NAME while + * GetPropertyLength() returns S_FALSE. This means in GetPropertyLength() the check for property + * existence happens before the check of Uri_DISPLAY_NO_FRAGMENT for property */ + { "http://www.winehq.org/foo.html#fragment", 0, S_OK, FALSE, Uri_DISPLAY_NO_FRAGMENT, + { + {NULL,E_INVALIDARG,FALSE}, + {NULL,E_INVALIDARG,FALSE}, + {"http://www.winehq.org/foo.html%22,S_OK,FALSE%7D, /* DISPLAY_URI */ + {NULL,E_INVALIDARG,FALSE}, + {NULL,E_INVALIDARG,FALSE}, + {NULL,E_INVALIDARG,FALSE}, + {NULL,E_INVALIDARG,FALSE}, + {NULL,E_INVALIDARG,FALSE,NULL,"",S_FALSE}, /* PASSWORD */ + {NULL,E_INVALIDARG,FALSE}, + {NULL,E_INVALIDARG,FALSE}, + {NULL,E_INVALIDARG,FALSE,NULL,"",S_FALSE}, /* QUERY */ + {NULL,E_INVALIDARG,FALSE}, + {NULL,E_INVALIDARG,FALSE}, + {NULL,E_INVALIDARG,FALSE,NULL,"",S_FALSE}, /* USER_INFO */ + {NULL,E_INVALIDARG,FALSE,NULL,"",S_FALSE}, /* USER_NAME */ + }, + { + {Uri_HOST_DNS,S_OK,FALSE}, + {80,S_OK,FALSE}, + {URL_SCHEME_HTTP,S_OK,FALSE}, + {URLZONE_INVALID,E_NOTIMPL,FALSE} + } + }, + /* Uri_DISPLAY_NO_FRAGMENT with a URI that has PASSWORD, QUERY, USER_INFO and USER_NAME */ + { "http://username:password@www.winehq.org/foo.html?query=value#fragment", 0, S_OK, FALSE, Uri_DISPLAY_NO_FRAGMENT, + { + {NULL,E_INVALIDARG,FALSE}, + {NULL,E_INVALIDARG,FALSE}, + {"http://www.winehq.org/foo.html?query=value%22,S_OK,FALSE%7D, /* DISPLAY_URI */ + {NULL,E_INVALIDARG,FALSE}, + {NULL,E_INVALIDARG,FALSE}, + {NULL,E_INVALIDARG,FALSE}, + {NULL,E_INVALIDARG,FALSE}, + {NULL,E_INVALIDARG,FALSE}, + {NULL,E_INVALIDARG,FALSE}, + {NULL,E_INVALIDARG,FALSE}, + {NULL,E_INVALIDARG,FALSE}, + {NULL,E_INVALIDARG,FALSE}, + {NULL,E_INVALIDARG,FALSE}, + {NULL,E_INVALIDARG,FALSE}, + {NULL,E_INVALIDARG,FALSE}, + }, + { + {Uri_HOST_DNS,S_OK,FALSE}, + {80,S_OK,FALSE}, + {URL_SCHEME_HTTP,S_OK,FALSE}, + {URLZONE_INVALID,E_NOTIMPL,FALSE} + } + }, + /* Uri_PUNYCODE_IDN_HOST with a ASCII host name that has no EXTENSION, FRAGMENT, PASSWORD, QUERY, USER_INFO and USER_NAME. + * GetPropertyBSTR() returns E_INVALIDARG for EXTENSION, FRAGMENT, PASSWORD, QUERY, USER_INFO + * and USER_NAME while GetPropertyLength() returns S_FALSE. This means the check for property + * existence happens before the check of Uri_PUNYCODE_IDN_HOST for property */ + { "http://www.winehq.org/", 0, S_OK, FALSE, Uri_PUNYCODE_IDN_HOST, + { + {"http://www.winehq.org/%22,S_OK,FALSE%7D, + {NULL,E_INVALIDARG,FALSE}, + {NULL,E_INVALIDARG,FALSE}, + {"winehq.org",S_OK,FALSE}, + {NULL,E_INVALIDARG,FALSE,NULL,"",S_FALSE}, /* EXTENSION */ + {NULL,E_INVALIDARG,FALSE,NULL,"",S_FALSE}, /* FRAGMENT */ + {"www.winehq.org",S_OK,FALSE}, + {NULL,E_INVALIDARG,FALSE,NULL,"",S_FALSE}, /* PASSWORD */ + {NULL,E_INVALIDARG,FALSE}, + {NULL,E_INVALIDARG,FALSE}, + {NULL,E_INVALIDARG,FALSE,NULL,"",S_FALSE}, /* QUERY */ + {NULL,E_INVALIDARG,FALSE}, + {NULL,E_INVALIDARG,FALSE}, + {NULL,E_INVALIDARG,FALSE,NULL,"",S_FALSE}, /* USER_INFO */ + {NULL,E_INVALIDARG,FALSE,NULL,"",S_FALSE}, /* USER_NAME */ + }, + { + {Uri_HOST_DNS,S_OK,FALSE}, + {80,S_OK,FALSE}, + {URL_SCHEME_HTTP,S_OK,FALSE}, + {URLZONE_INVALID,E_NOTIMPL,FALSE} + } + }, + /* Uri_PUNYCODE_IDN_HOST with a ASCII host name that has EXTENSION, FRAGMENT, PASSWORD, QUERY, USER_INFO and USER_NAME */ + { "http://username:password@www.winehq.org/index.html?query=value#fragment", 0, S_OK, FALSE, Uri_PUNYCODE_IDN_HOST, + { + {"http://username:password@www.winehq.org/index.html?query=value#fragment%22,S..., + {NULL,E_INVALIDARG,FALSE}, + {NULL,E_INVALIDARG,FALSE}, + {"winehq.org",S_OK,FALSE}, + {NULL,E_INVALIDARG,FALSE}, + {NULL,E_INVALIDARG,FALSE}, + {"www.winehq.org",S_OK,FALSE}, + {NULL,E_INVALIDARG,FALSE}, + {NULL,E_INVALIDARG,FALSE}, + {NULL,E_INVALIDARG,FALSE}, + {NULL,E_INVALIDARG,FALSE}, + {NULL,E_INVALIDARG,FALSE}, + {NULL,E_INVALIDARG,FALSE}, + {NULL,E_INVALIDARG,FALSE}, + {NULL,E_INVALIDARG,FALSE}, + }, + { + {Uri_HOST_DNS,S_OK,FALSE}, + {80,S_OK,FALSE}, + {URL_SCHEME_HTTP,S_OK,FALSE}, + {URLZONE_INVALID,E_NOTIMPL,FALSE} + } + }, + /* Uri_PUNYCODE_IDN_HOST with an IDN that has EXTENSION, FRAGMENT, PASSWORD, QUERY, USER_INFO and USER_NAME */ + { + /* "http://username:password@%E6%B5%8B%E8%AF%95.org/index.html?query=value#fragm..." with Chinese in UTF-8 encoding */ + "http://username:password@%5CxE6%5CxB5%5Cx8B%5CxE8%5CxAF%5Cx95.org/index.html...", 0, S_OK, FALSE, Uri_PUNYCODE_IDN_HOST, + { + {"http://username:password@xn--0zwm56d.org/index.html?query=value#fragment%22,..., + {NULL,E_INVALIDARG,FALSE}, + {NULL,E_INVALIDARG,FALSE}, + {"xn--0zwm56d.org",S_OK,FALSE}, + {NULL,E_INVALIDARG,FALSE}, + {NULL,E_INVALIDARG,FALSE}, + {"xn--0zwm56d.org",S_OK,FALSE}, + {NULL,E_INVALIDARG,FALSE}, + {NULL,E_INVALIDARG,FALSE}, + {NULL,E_INVALIDARG,FALSE}, + {NULL,E_INVALIDARG,FALSE}, + {NULL,E_INVALIDARG,FALSE}, + {NULL,E_INVALIDARG,FALSE}, + {NULL,E_INVALIDARG,FALSE}, + {NULL,E_INVALIDARG,FALSE}, + }, + { + {Uri_HOST_IDN,S_OK,FALSE}, + {80,S_OK,FALSE}, + {URL_SCHEME_HTTP,S_OK,FALSE}, + {URLZONE_INVALID,E_NOTIMPL,FALSE} + } + }, + { + /* "http://username:password@www.%E6%B5%8B%E8%AF%95.org/index.html?query=value#f..." with Chinese in UTF-8 encoding */ + "http://username:password@www.%5CxE6%5CxB5%5Cx8B%5CxE8%5CxAF%5Cx95.org/index....", 0, S_OK, FALSE, Uri_PUNYCODE_IDN_HOST, + { + {"http://username:password@www.xn--0zwm56d.org/index.html?query=value#fragment..., + {NULL,E_INVALIDARG,FALSE}, + {NULL,E_INVALIDARG,FALSE}, + {"xn--0zwm56d.org",S_OK,FALSE}, + {NULL,E_INVALIDARG,FALSE}, + {NULL,E_INVALIDARG,FALSE}, + {"www.xn--0zwm56d.org",S_OK,FALSE}, + {NULL,E_INVALIDARG,FALSE}, + {NULL,E_INVALIDARG,FALSE}, + {NULL,E_INVALIDARG,FALSE}, + {NULL,E_INVALIDARG,FALSE}, + {NULL,E_INVALIDARG,FALSE}, + {NULL,E_INVALIDARG,FALSE}, + {NULL,E_INVALIDARG,FALSE}, + {NULL,E_INVALIDARG,FALSE}, + }, + { + {Uri_HOST_IDN,S_OK,FALSE}, + {80,S_OK,FALSE}, + {URL_SCHEME_HTTP,S_OK,FALSE}, + {URLZONE_INVALID,E_NOTIMPL,FALSE} + } + }, + /* Uri_PUNYCODE_IDN_HOST with an IDN that has EXTENSION, FRAGMENT, PASSWORD, QUERY, USER_INFO and USER_NAME. + * User info is ":@" and not removed in the Uri_PROPERTY_ABSOLUTE_URI property */ + { + /* "http://:@www.%E6%B5%8B%E8%AF%95.org/index.html?query=value#fragment" with Chinese in UTF-8 encoding */ + "http://:@www.%5CxE6%5CxB5%5Cx8B%5CxE8%5CxAF%5Cx95.org/index.html?query=value...", 0, S_OK, FALSE, Uri_PUNYCODE_IDN_HOST, + { + {"http://:@www.xn--0zwm56d.org/index.html?query=value#fragment%22,S_OK,FALSE%7..., + {NULL,E_INVALIDARG,FALSE}, + {NULL,E_INVALIDARG,FALSE}, + {"xn--0zwm56d.org",S_OK,FALSE}, + {NULL,E_INVALIDARG,FALSE}, + {NULL,E_INVALIDARG,FALSE}, + {"www.xn--0zwm56d.org",S_OK,FALSE}, + {NULL,E_INVALIDARG,FALSE}, + {NULL,E_INVALIDARG,FALSE}, + {NULL,E_INVALIDARG,FALSE}, + {NULL,E_INVALIDARG,FALSE}, + {NULL,E_INVALIDARG,FALSE}, + {NULL,E_INVALIDARG,FALSE}, + {NULL,E_INVALIDARG,FALSE}, + {NULL,E_INVALIDARG,FALSE,NULL,"",S_FALSE}, /* USER_NAME */ + }, + { + {Uri_HOST_IDN,S_OK,FALSE}, + {80,S_OK,FALSE}, + {URL_SCHEME_HTTP,S_OK,FALSE}, + {URLZONE_INVALID,E_NOTIMPL,FALSE} + } + }, + /* Uri_PUNYCODE_IDN_HOST with an IDN that has EXTENSION, FRAGMENT, PASSWORD, QUERY, USER_INFO and USER_NAME. + * User info is "@" and not removed in the Uri_PROPERTY_ABSOLUTE_URI property */ + {/* "http://@www.%E6%B5%8B%E8%AF%95.org/index.html?query=value#fragment" with Chinese in UTF-8 encoding */ + "http://@www.%5CxE6%5CxB5%5Cx8B%5CxE8%5CxAF%5Cx95.org/index.html?query=value#...", 0, S_OK, FALSE, Uri_PUNYCODE_IDN_HOST, + { + {"http://@www.xn--0zwm56d.org/index.html?query=value#fragment%22,S_OK,FALSE%7D, + {NULL,E_INVALIDARG,FALSE}, + {NULL,E_INVALIDARG,FALSE}, + {"xn--0zwm56d.org",S_OK,FALSE}, + {NULL,E_INVALIDARG,FALSE}, + {NULL,E_INVALIDARG,FALSE}, + {"www.xn--0zwm56d.org",S_OK,FALSE}, + {NULL,E_INVALIDARG,FALSE,NULL,"",S_FALSE}, /* PASSWORD */ + {NULL,E_INVALIDARG,FALSE}, + {NULL,E_INVALIDARG,FALSE}, + {NULL,E_INVALIDARG,FALSE}, + {NULL,E_INVALIDARG,FALSE}, + {NULL,E_INVALIDARG,FALSE}, + {NULL,E_INVALIDARG,FALSE}, + {NULL,E_INVALIDARG,FALSE,NULL,"",S_FALSE}, /* USER_NAME */ + }, + { + {Uri_HOST_IDN,S_OK,FALSE}, + {80,S_OK,FALSE}, + {URL_SCHEME_HTTP,S_OK,FALSE}, + {URLZONE_INVALID,E_NOTIMPL,FALSE} + } + }, + /* Uri_PUNYCODE_IDN_HOST with a path in Unicode characters */ + { + /* "http://username:password@winehq.org/%E6%B5%8B%E8%AF%95.html?query=value#frag..." with Chinese in UTF-8 encoding */ + "http://username:password@winehq.org/%5CxE6%5CxB5%5Cx8B%5CxE8%5CxAF%5Cx95.htm...", 0, S_OK, FALSE, Uri_PUNYCODE_IDN_HOST, + { + {"http://username:password@winehq.org/%5CxE6%5CxB5%5Cx8B%5CxE8%5CxAF%5Cx95.htm..., + {NULL,E_INVALIDARG,FALSE}, + {NULL,E_INVALIDARG,FALSE}, + {"winehq.org",S_OK,FALSE}, + {NULL,E_INVALIDARG,FALSE}, + {NULL,E_INVALIDARG,FALSE}, + {"winehq.org",S_OK,FALSE}, + {NULL,E_INVALIDARG,FALSE}, + {NULL,E_INVALIDARG,FALSE}, + {NULL,E_INVALIDARG,FALSE}, + {NULL,E_INVALIDARG,FALSE}, + {NULL,E_INVALIDARG,FALSE}, + {NULL,E_INVALIDARG,FALSE}, + {NULL,E_INVALIDARG,FALSE}, + {NULL,E_INVALIDARG,FALSE}, + }, + { + {Uri_HOST_DNS,S_OK,FALSE}, + {80,S_OK,FALSE}, + {URL_SCHEME_HTTP,S_OK,FALSE}, + {URLZONE_INVALID,E_NOTIMPL,FALSE} + } + }, + /* Uri_DISPLAY_IDN_HOST with an IDN and URI has no EXTENSION, FRAGMENT, PASSWORD, QUERY, USER_INFO and USER_NAME. + * GetPropertyBSTR() returns E_INVALIDARG for EXTENSION, FRAGMENT, PASSWORD, QUERY, USER_INFO + * and USER_NAME while GetPropertyLength() returns S_FALSE. This means the check for property + * existence happens before the check of Uri_DISPLAY_IDN_HOST for property */ + { + /* "http://%E6%B5%8B%E8%AF%95.org/" with Chinese in UTF-8 encoding */ + "http://%5CxE6%5CxB5%5Cx8B%5CxE8%5CxAF%5Cx95.org/", 0, S_OK, FALSE, Uri_DISPLAY_IDN_HOST, + { + {"http://xn--0zwm56d.org/%22,S_OK,FALSE,NULL,%22http://%5CxE6%5CxB5%5Cx8B%5CxE..., + {NULL,E_INVALIDARG,FALSE}, + {NULL,E_INVALIDARG,FALSE}, + {"xn--0zwm56d.org",S_OK,FALSE,NULL,"\xE6\xB5\x8B\xE8\xAF\x95.org",S_OK}, + {NULL,E_INVALIDARG,FALSE,NULL,"",S_FALSE}, /* EXTENSION */ + {NULL,E_INVALIDARG,FALSE,NULL,"",S_FALSE}, /* FRAGMENT */ + {"xn--0zwm56d.org",S_OK,FALSE,NULL,"\xE6\xB5\x8B\xE8\xAF\x95.org",S_OK}, + {NULL,E_INVALIDARG,FALSE,NULL,"",S_FALSE}, /* PASSWORD */ + {NULL,E_INVALIDARG,FALSE}, + {NULL,E_INVALIDARG,FALSE}, + {NULL,E_INVALIDARG,FALSE,NULL,"",S_FALSE}, /* QUERY */ + {NULL,E_INVALIDARG,FALSE}, + {NULL,E_INVALIDARG,FALSE}, + {NULL,E_INVALIDARG,FALSE,NULL,"",S_FALSE}, /* USER_INFO */ + {NULL,E_INVALIDARG,FALSE,NULL,"",S_FALSE}, /* USER_NAME */ + }, + { + {Uri_HOST_IDN,S_OK,FALSE}, + {80,S_OK,FALSE}, + {URL_SCHEME_HTTP,S_OK,FALSE}, + {URLZONE_INVALID,E_NOTIMPL,FALSE} + } + }, + /* Uri_DISPLAY_IDN_HOST with an IDN and URI has EXTENSION, FRAGMENT, PASSWORD, QUERY, USER_INFO and USER_NAME.*/ + { + /* "http://username:password@%E6%B5%8B%E8%AF%95.org/index.html?query=value#fragm..." with Chinese in UTF-8 encoding */ + "http://username:password@%5CxE6%5CxB5%5Cx8B%5CxE8%5CxAF%5Cx95.org/index.html...", 0, S_OK, FALSE, Uri_DISPLAY_IDN_HOST, + { + {"http://username:password@xn--0zwm56d.org/index.html?query=value#fragment%22,..., + {NULL,E_INVALIDARG,FALSE}, + {NULL,E_INVALIDARG,FALSE}, + {"xn--0zwm56d.org",S_OK,FALSE,NULL,"\xE6\xB5\x8B\xE8\xAF\x95.org",S_OK}, + {NULL,E_INVALIDARG,FALSE}, + {NULL,E_INVALIDARG,FALSE}, + {"xn--0zwm56d.org",S_OK,FALSE,NULL,"\xE6\xB5\x8B\xE8\xAF\x95.org",S_OK}, + {NULL,E_INVALIDARG,FALSE}, + {NULL,E_INVALIDARG,FALSE}, + {NULL,E_INVALIDARG,FALSE}, + {NULL,E_INVALIDARG,FALSE}, + {NULL,E_INVALIDARG,FALSE}, + {NULL,E_INVALIDARG,FALSE}, + {NULL,E_INVALIDARG,FALSE}, + {NULL,E_INVALIDARG,FALSE}, + }, + { + {Uri_HOST_IDN,S_OK,FALSE}, + {80,S_OK,FALSE}, + {URL_SCHEME_HTTP,S_OK,FALSE}, + {URLZONE_INVALID,E_NOTIMPL,FALSE} + } + }, + /* Multiple flags */ + { "http://username:password@winehq.org/index.html?query=value#fragment", 0, S_OK, FALSE, Uri_DISPLAY_NO_FRAGMENT | Uri_DISPLAY_IDN_HOST, + { + {NULL,E_INVALIDARG,FALSE}, + {NULL,E_INVALIDARG,FALSE}, + {NULL,E_INVALIDARG,FALSE}, + {NULL,E_INVALIDARG,FALSE}, + {NULL,E_INVALIDARG,FALSE}, + {NULL,E_INVALIDARG,FALSE}, + {NULL,E_INVALIDARG,FALSE}, + {NULL,E_INVALIDARG,FALSE}, + {NULL,E_INVALIDARG,FALSE}, + {NULL,E_INVALIDARG,FALSE}, + {NULL,E_INVALIDARG,FALSE}, + {NULL,E_INVALIDARG,FALSE}, + {NULL,E_INVALIDARG,FALSE}, + {NULL,E_INVALIDARG,FALSE}, + {NULL,E_INVALIDARG,FALSE}, + }, + { + {Uri_HOST_DNS,S_OK,FALSE}, /* HOST_TYPE */ + {80,S_OK,FALSE}, /* PORT */ + {URL_SCHEME_HTTP,S_OK,FALSE}, /* SCHEME */ + {URLZONE_INVALID,E_NOTIMPL,FALSE} /* ZONE */ + } + }, };
typedef struct _invalid_uri { @@ -7945,7 +8337,7 @@ static void test_IUri_GetPropertyBSTR(void) { BSTR received = NULL; uri_str_property prop = test.str_props[j];
- hr = IUri_GetPropertyBSTR(uri, j, &received, 0); + hr = IUri_GetPropertyBSTR(uri, j, &received, test.flags); todo_wine_if(prop.todo) { ok(hr == prop.expected || (prop.value2 && hr == prop.expected2), @@ -8083,6 +8475,8 @@ static void test_IUri_GetStrProperties(void) { LPWSTR uriW; uri = NULL;
+ if (test.flags) continue; + uriW = a2w(test.uri); hr = pCreateUri(uriW, test.create_flags, 0, &uri); todo_wine_if(test.create_todo) @@ -8122,9 +8516,11 @@ static void test_IUri_GetStrProperties(void) { prop = test.str_props[Uri_PROPERTY_DISPLAY_URI]; hr = IUri_GetDisplayUri(uri, &received); todo_wine_if(prop.todo) { - ok(hr == prop.expected, "Error: GetDisplayUri returned 0x%08lx, expected 0x%08lx on uri_tests[%ld].\n", - hr, prop.expected, i); - ok(!strcmp_aw(prop.value, received) || broken(prop.broken_value && !strcmp_aw(prop.broken_value, received)), + ok(hr == prop.expected, + "Error: GetDisplayUri returned 0x%08lx, expected 0x%08lx on uri_tests[%ld].\n", + hr, prop.expected, i); + ok(!strcmp_aw(prop.value, received) || (prop.value2 && !strcmp_aw(prop.value2, received)) + || broken(prop.broken_value && !strcmp_aw(prop.broken_value, received)), "Error: Expected %s but got %s on uri_tests[%ld].\n", prop.value, wine_dbgstr_w(received), i); } @@ -8407,25 +8803,45 @@ static void test_IUri_GetPropertyLength(void) { DWORD j;
for(j = Uri_PROPERTY_STRING_START; j <= Uri_PROPERTY_STRING_LAST; ++j) { - DWORD expectedLen, receivedLen; + DWORD expectedLen, expectedLen2, receivedLen; uri_str_property prop = test.str_props[j]; LPWSTR expectedValueW;
- expectedLen = lstrlenA(prop.value); - /* Value may be unicode encoded */ - expectedValueW = a2w(prop.value); - expectedLen = lstrlenW(expectedValueW); - free(expectedValueW); + if (prop.value) + { + expectedLen = lstrlenA(prop.value); + /* Value may be unicode encoded */ + expectedValueW = a2w(prop.value); + expectedLen = lstrlenW(expectedValueW); + free(expectedValueW); + } + else + { + expectedLen = 0; + } + + if (prop.value2) + { + expectedLen2 = lstrlenA(prop.value2); + /* Value may be unicode encoded */ + expectedValueW = a2w(prop.value2); + expectedLen2 = lstrlenW(expectedValueW); + free(expectedValueW); + } + else + { + expectedLen2 = 0; + }
/* This won't be necessary once GetPropertyLength is implemented. */ receivedLen = -1;
- hr = IUri_GetPropertyLength(uri, j, &receivedLen, 0); + hr = IUri_GetPropertyLength(uri, j, &receivedLen, test.flags); todo_wine_if(prop.todo) { ok(hr == prop.expected || (prop.value2 && hr == prop.expected2), "Error: GetPropertyLength returned 0x%08lx, expected 0x%08lx on uri_tests[%ld].str_props[%ld].\n", hr, prop.expected, i, j); - ok(receivedLen == expectedLen || (prop.value2 && receivedLen == lstrlenA(prop.value2)) || + ok(receivedLen == expectedLen || (prop.value2 && receivedLen == expectedLen2) || broken(prop.broken_value && receivedLen == lstrlenA(prop.broken_value)), "Error: Expected a length of %ld but got %ld on uri_tests[%ld].str_props[%ld].\n", expectedLen, receivedLen, i, j); @@ -8481,6 +8897,8 @@ static void test_IUri_GetProperties(void) { LPWSTR uriW; uri = NULL;
+ if (test.flags) continue; + uriW = a2w(test.uri); hr = pCreateUri(uriW, test.create_flags, 0, &uri); todo_wine_if(test.create_todo) @@ -8530,6 +8948,8 @@ static void test_IUri_HasProperty(void) { LPWSTR uriW; uri = NULL;
+ if (test.flags) continue; + uriW = a2w(test.uri);
hr = pCreateUri(uriW, test.create_flags, 0, &uri); @@ -11407,7 +11827,7 @@ static void test_IPersistStream(void) BSTR raw_uri; HRESULT hr;
- if(test->create_todo || test->create_expected!=S_OK) + if(test->create_todo || test->create_expected!=S_OK || test->flags) continue;
uriW = a2w(test->uri);
Hi,
It looks like your patch introduced the new failures shown below. Please investigate and fix them before resubmitting your patch. If they are not new, fixing them anyway would help a lot. Otherwise please ask for the known failures list to be updated.
The full results can be found at: https://testbot.winehq.org/JobDetails.pl?Key=149639
Your paranoid android.
=== debian11 (build log) ===
error: patch failed: dlls/urlmon/tests/uri.c:131 Task: Patch failed to apply
=== debian11b (build log) ===
error: patch failed: dlls/urlmon/tests/uri.c:131 Task: Patch failed to apply
This merge request was approved by Jacek Caban.