35#define TEST_URL "http://www.winehq.org/site/about#hi"
36#define TEST_URL3 "file:///C:/Program%20Files/Atmel/AVR%20Tools/STK500/STK500.xml"
38#define CREATE_URL1 "http://username:password@www.winehq.org/site/about"
39#define CREATE_URL2 "http://username@www.winehq.org/site/about"
40#define CREATE_URL3 "http://username:"
41#define CREATE_URL4 "http://www.winehq.org/site/about"
42#define CREATE_URL5 "http://"
43#define CREATE_URL6 "nhttp://username:password@www.winehq.org:80/site/about"
44#define CREATE_URL7 "http://username:password@www.winehq.org:42/site/about"
45#define CREATE_URL8 "https://username:password@www.winehq.org/site/about"
46#define CREATE_URL9 "about:blank"
47#define CREATE_URL10 "about://host/blank"
48#define CREATE_URL11 "about:"
49#define CREATE_URL12 "http://www.winehq.org:65535"
50#define CREATE_URL13 "http://localhost/?test=123"
63 dst->dwSchemeLength = scheLen;
64 dst->dwHostNameLength = hostLen;
65 dst->dwUserNameLength = userLen;
66 dst->dwPasswordLength = passLen;
67 dst->dwUrlPathLength = pathLen;
68 dst->dwExtraInfoLength = extrLen;
83 dst->dwSchemeLength = scheLen;
84 dst->dwHostNameLength = hostLen;
85 dst->dwUserNameLength = userLen;
86 dst->dwPasswordLength = passLen;
87 dst->dwUrlPathLength = pathLen;
88 dst->dwExtraInfoLength = extrLen;
118 {
"http://www.winehq.org/site/about#hi",
119 0, 4,
INTERNET_SCHEME_HTTP, 7, 14, -1, 80, -1, 0, -1, 0, 21, 11, 32, 3,
120 "http",
"www.winehq.org",
"",
"",
"/site/about",
"#hi"},
121 {
"http://www.myserver.com/myscript.php?arg=1",
122 0, 4,
INTERNET_SCHEME_HTTP, 7, 16, -1, 80, -1, 0, -1, 0, 23, 13, 36, 6,
123 "http",
"www.myserver.com",
"",
"",
"/myscript.php",
"?arg=1"},
124 {
"http://www.winehq.org?test=123",
125 0, 4,
INTERNET_SCHEME_HTTP, 7, 14, 23, 80, -1, 0, -1, 0, 21, 0, 21, 9,
126 "http",
"www.winehq.org",
"",
"",
"",
"?test=123"},
127 {
"http://www.winehq.org/myscript.php;test=123",
128 0, 4,
INTERNET_SCHEME_HTTP, 7, 14, 23, 80, -1, 0, -1, 0, 21, 22, -1, 0,
129 "http",
"www.winehq.org",
"",
"",
"/myscript.php;test=123",
""},
130 {
"HtTp://www.winehq.org/scheme",
131 0, 4,
INTERNET_SCHEME_HTTP, 7, 14, 23, 80, -1, 0, -1, 0, 21, 7, -1, 0,
132 "HtTp",
"www.winehq.org",
"",
"",
"/scheme",
""},
133 {
"http://www.winehq.org",
134 0, 4,
INTERNET_SCHEME_HTTP, 7, 14, 23, 80, -1, 0, -1, 0, 21, 0, -1, 0,
135 "http",
"www.winehq.org",
"",
"",
"",
""},
136 {
"file:///C:/Program%20Files/Atmel/AVR%20Tools/STK500/STK500.xml",
137 0, 4,
INTERNET_SCHEME_FILE, -1, 0, -1, 0, -1, 0, -1, 0, 7, 55, -1, 0,
138 "file",
"",
"",
"",
"C:\\Program Files\\Atmel\\AVR Tools\\STK500\\STK500.xml",
""},
139 {
"fide:///C:/Program%20Files/Atmel/AVR%20Tools/STK500/STK500.xml",
140 0, 4,
INTERNET_SCHEME_UNKNOWN, 7, 0, -1, 0, -1, 0, -1, 0, 7, 55, -1, 0,
141 "fide",
"",
"",
"",
"/C:/Program%20Files/Atmel/AVR%20Tools/STK500/STK500.xml",
""},
142 {
"file://C:/Program%20Files/Atmel/AVR%20Tools/STK500/STK500.xml",
143 0, 4,
INTERNET_SCHEME_FILE, -1, 0, -1, 0, -1, 0, -1, 0, 7, 54, -1, 0,
144 "file",
"",
"",
"",
"C:\\Program%20Files\\Atmel\\AVR%20Tools\\STK500\\STK500.xml",
""},
145 {
"file://C:/Program%20Files/Atmel/..",
146 0, 4,
INTERNET_SCHEME_FILE, -1, 0, -1, 0, -1, 0, -1, 0, 7, 27, -1, 0,
147 "file",
"",
"",
"",
"C:\\Program%20Files\\Atmel\\..\\",
""},
148 {
"file://C:/Program%20Files/Atmel/../Asdf.xml",
149 0, 4,
INTERNET_SCHEME_FILE, -1, 0, -1, 0, -1, 0, -1, 0, 7, 36, -1, 0,
150 "file",
"",
"",
"",
"C:\\Program%20Files\\Atmel\\..\\Asdf.xml",
""},
151 {
"file:///C:/Program%20Files/Atmel/..",
152 0, 4,
INTERNET_SCHEME_FILE, -1, 0, -1, 0, -1, 0, -1, 0, 7, 28, -1, 0,
153 "file",
"",
"",
"",
"C:\\Program Files\\Atmel\\..\\",
""},
154 {
"file:///C:/Program%20Files/Atmel/../Asdf.xml",
155 0, 4,
INTERNET_SCHEME_FILE, -1, 0, -1, 0, -1, 0, -1, 0, 7, 37, -1, 0,
156 "file",
"",
"",
"",
"C:\\Program Files\\Atmel\\..\\Asdf.xml",
""},
157 {
"file://C:/Program%20Files/Atmel/.",
158 0, 4,
INTERNET_SCHEME_FILE, -1, 0, -1, 0, -1, 0, -1, 0, 7, 26, -1, 0,
159 "file",
"",
"",
"",
"C:\\Program%20Files\\Atmel\\.\\",
""},
160 {
"file://C:/Program%20Files/Atmel/./Asdf.xml",
161 0, 4,
INTERNET_SCHEME_FILE, -1, 0, -1, 0, -1, 0, -1, 0, 7, 35, -1, 0,
162 "file",
"",
"",
"",
"C:\\Program%20Files\\Atmel\\.\\Asdf.xml",
""},
163 {
"file:///C:/Program%20Files/Atmel/.",
164 0, 4,
INTERNET_SCHEME_FILE, -1, 0, -1, 0, -1, 0, -1, 0, 7, 27, -1, 0,
165 "file",
"",
"",
"",
"C:\\Program Files\\Atmel\\.\\",
""},
166 {
"file:///C:/Program%20Files/Atmel/./Asdf.xml",
167 0, 4,
INTERNET_SCHEME_FILE, -1, 0, -1, 0, -1, 0, -1, 0, 7, 36, -1, 0,
168 "file",
"",
"",
"",
"C:\\Program Files\\Atmel\\.\\Asdf.xml",
""},
170 0, 1,
INTERNET_SCHEME_UNKNOWN, -1, 0, -1, 0, -1, 0, -1, 0, 2, 9, -1, 0,
171 "C",
"",
"",
"",
"\\file.txt",
""},
172 {
"res://IELib.dll/test.htm",
173 0, 3,
INTERNET_SCHEME_RES, 6, 9, -1, 0, -1, 0, -1, 0, 15, 9, -1, 0,
174 "res",
"IELib.dll",
"",
"",
"/test.htm",
""},
175 {
"gopher://www.winehq.org/site/about#hi",
176 0, 6,
INTERNET_SCHEME_GOPHER, 9, 14, -1, 0, -1, 0, -1, 0, 23, 11, 34, 3,
177 "gopher",
"www.winehq.org",
"",
"",
"/site/about",
"#hi"},
203 char *scheme_a, *hostname_a, *username_a;
204 char *password_a, *extrainfo_a, *urlpath_a;
205 WCHAR *scheme_w, *hostname_w, *username_w;
206 WCHAR *password_w, *extrainfo_w, *urlpath_w;
217 if(
test->scheme_off == -1)
218 ok(!
url.lpszScheme,
"[%s] url.lpszScheme = %p, expected NULL\n",
test->url,
url.lpszScheme);
220 ok(
url.lpszScheme ==
test->url+
test->scheme_off,
"[%s] url.lpszScheme = %p, expected %p\n",
222 ok(
url.dwSchemeLength ==
test->scheme_len,
"[%s] url.lpszSchemeLength = %d, expected %d\n",
225 ok(
url.nScheme ==
test->scheme,
"[%s] url.nScheme = %d, expected %d\n",
test->url,
url.nScheme,
test->scheme);
227 if(
test->host_off == -1)
228 ok(!
url.lpszHostName,
"[%s] url.lpszHostName = %p, expected NULL\n",
test->url,
url.lpszHostName);
230 ok(
url.lpszHostName ==
test->url+
test->host_off,
"[%s] url.lpszHostName = %p, expected %p\n",
232 if(
test->host_skip_broken != -1 &&
url.dwHostNameLength ==
test->host_skip_broken) {
233 win_skip(
"skipping broken dwHostNameLength result\n");
236 ok(
url.dwHostNameLength ==
test->host_len,
"[%s] url.lpszHostNameLength = %d, expected %d\n",
239 ok(
url.nPort ==
test->port,
"[%s] nPort = %d, expected %d\n",
test->url,
url.nPort,
test->port);
241 if(
test->user_off == -1)
242 ok(!
url.lpszUserName,
"[%s] url.lpszUserName = %p\n",
test->url,
url.lpszUserName);
244 ok(
url.lpszUserName ==
test->url+
test->user_off,
"[%s] url.lpszUserName = %p, expected %p\n",
246 ok(
url.dwUserNameLength ==
test->user_len,
"[%s] url.lpszUserNameLength = %d, expected %d\n",
249 if(
test->pass_off == -1)
250 ok(!
url.lpszPassword,
"[%s] url.lpszPassword = %p\n",
test->url,
url.lpszPassword);
252 ok(
url.lpszPassword ==
test->url+
test->pass_off,
"[%s] url.lpszPassword = %p, expected %p\n",
254 ok(
url.dwPasswordLength ==
test->pass_len,
"[%s] url.lpszPasswordLength = %d, expected %d\n",
257 if(
test->path_off == -1)
258 ok(!
url.lpszUrlPath,
"[%s] url.lpszUrlPath = %p, expected NULL\n",
test->url,
url.lpszUrlPath);
260 ok(
url.lpszUrlPath ==
test->url+
test->path_off,
"[%s] url.lpszUrlPath = %p, expected %p\n",
262 ok(
url.dwUrlPathLength ==
test->path_len,
"[%s] url.lpszUrlPathLength = %d, expected %d\n",
265 if(
test->extra_off == -1)
266 ok(!
url.lpszExtraInfo,
"[%s] url.lpszExtraInfo = %p, expected NULL\n",
test->url,
url.lpszExtraInfo);
268 ok(
url.lpszExtraInfo ==
test->url+
test->extra_off,
"[%s] url.lpszExtraInfo = %p, expected %p\n",
270 ok(
url.dwExtraInfoLength ==
test->extra_len,
"[%s] url.lpszExtraInfoLength = %d, expected %d\n",
271 test->url,
url.dwExtraInfoLength,
test->extra_len);
286 win_skip(
"InternetCrackUrlW is not implemented\n");
292 if(
test->scheme_off == -1)
302 if(
test->host_off == -1) {
315 if(
test->user_off == -1) {
326 if(
test->pass_off == -1) {
337 if(
test->path_off == -1)
345 if(
test->extra_off == -1) {
365 url.lpszScheme = scheme_a;
366 url.dwSchemeLength = buf_len;
367 url.lpszHostName = hostname_a;
368 url.dwHostNameLength = buf_len;
369 url.lpszUserName = username_a;
370 url.dwUserNameLength = buf_len;
371 url.lpszPassword = password_a;
372 url.dwPasswordLength = buf_len;
373 url.lpszUrlPath = urlpath_a;
374 url.dwUrlPathLength = buf_len;
375 url.lpszExtraInfo = extrainfo_a;
376 url.dwExtraInfoLength = buf_len;
381 ok(
url.dwSchemeLength ==
strlen(
test->exp_scheme),
"[%s] Got wrong scheme length: %d\n",
382 test->url,
url.dwSchemeLength);
383 ok(!
strcmp(scheme_a,
test->exp_scheme),
"[%s] Got wrong scheme, expected: %s, got: %s\n",
384 test->url,
test->exp_scheme, scheme_a);
386 ok(
url.nScheme ==
test->scheme,
"[%s] Got wrong nScheme, expected: %d, got: %d\n",
389 ok(
url.dwHostNameLength ==
strlen(
test->exp_hostname),
"[%s] Got wrong hostname length: %d\n",
390 test->url,
url.dwHostNameLength);
391 ok(!
strcmp(hostname_a,
test->exp_hostname),
"[%s] Got wrong hostname, expected: %s, got: %s\n",
392 test->url,
test->exp_hostname, hostname_a);
394 ok(
url.nPort ==
test->port,
"[%s] Got wrong port, expected: %d, got: %d\n",
397 ok(
url.dwUserNameLength ==
strlen(
test->exp_username),
"[%s] Got wrong username length: %d\n",
398 test->url,
url.dwUserNameLength);
399 ok(!
strcmp(username_a,
test->exp_username),
"[%s] Got wrong username, expected: %s, got: %s\n",
400 test->url,
test->exp_username, username_a);
402 ok(
url.dwPasswordLength ==
strlen(
test->exp_password),
"[%s] Got wrong password length: %d\n",
403 test->url,
url.dwPasswordLength);
404 ok(!
strcmp(password_a,
test->exp_password),
"[%s] Got wrong password, expected: %s, got: %s\n",
405 test->url,
test->exp_password, password_a);
407 ok(
url.dwUrlPathLength ==
strlen(
test->exp_urlpath),
"[%s] Got wrong urlpath length: %d\n",
408 test->url,
url.dwUrlPathLength);
409 ok(!
strcmp(urlpath_a,
test->exp_urlpath),
"[%s] Got wrong urlpath, expected: %s, got: %s\n",
410 test->url,
test->exp_urlpath, urlpath_a);
412 ok(
url.dwExtraInfoLength ==
strlen(
test->exp_extrainfo),
"[%s] Got wrong extrainfo length: %d\n",
413 test->url,
url.dwExtraInfoLength);
414 ok(!
strcmp(extrainfo_a,
test->exp_extrainfo),
"[%s] Got wrong extrainfo, expected: %s, got: %s\n",
415 test->url,
test->exp_extrainfo, extrainfo_a);
438 ok(!
strcmp_wa(scheme_w,
test->exp_scheme),
"[%s] Got wrong scheme, expected: %s, got: %s\n",
441 ok(urlw.
nScheme ==
test->scheme,
"[%s] Got wrong nScheme, expected: %d, got: %d\n",
446 ok(!
strcmp_wa(hostname_w,
test->exp_hostname),
"[%s] Got wrong hostname, expected: %s, got: %s\n",
449 ok(urlw.
nPort ==
test->port,
"[%s] Got wrong port, expected: %d, got: %d\n",
454 ok(!
strcmp_wa(username_w,
test->exp_username),
"[%s] Got wrong username, expected: %s, got: %s\n",
459 ok(!
strcmp_wa(password_w,
test->exp_password),
"[%s] Got wrong password, expected: %s, got: %s\n",
464 ok(!
strcmp_wa(urlpath_w,
test->exp_urlpath),
"[%s] Got wrong urlpath, expected: %s, got: %s\n",
469 ok(!
strcmp_wa(extrainfo_w,
test->exp_extrainfo),
"[%s] Got wrong extrainfo, expected: %s, got: %s\n",
484 char long_url[
sizeof(long_buf) + 1000];
486 {long_url, 0, 4,
INTERNET_SCHEME_HTTP, 7, 14, -1, 80, -1, 0, -1, 0, 21,
sizeof(long_buf)-1, -1, 0,
487 "http",
"www.winehq.org",
"",
"", long_buf,
""};
489 {long_url, 0, 4,
INTERNET_SCHEME_HTTP, 7, 14, -1, 80, -1, 0, -1, 0, 21, 6, 27,
sizeof(long_buf)-1,
490 "http",
"www.winehq.org",
"",
"",
"/path/", long_buf};
494 memset(long_buf,
'x',
sizeof(long_buf));
496 long_buf[
sizeof(long_buf)-1] = 0;
498 strcpy(long_url,
"http://www.winehq.org");
499 strcat(long_url, long_buf);
502 strcpy(long_url,
"http://www.winehq.org/path/");
504 strcat(long_url, long_buf);
543 copy_compsA(&urlSrc, &urlComponents, 0, 1024, 1024, 1024, 1024, 1024);
548 copy_compsA(&urlSrc, &urlComponents, 32, 0, 1024, 1024, 1024, 1024);
552 ok(
ret==firstret && (
GLE==firstGLE),
"InternetCrackUrl returned %d with GLE=%d (expected to return %d)\n",
555 copy_compsA(&urlSrc, &urlComponents, 32, 1024, 0, 1024, 1024, 1024);
559 ok(
ret==firstret && (
GLE==firstGLE),
"InternetCrackUrl returned %d with GLE=%d (expected to return %d)\n",
562 copy_compsA(&urlSrc, &urlComponents, 32, 1024, 1024, 0, 1024, 1024);
566 ok(
ret==firstret && (
GLE==firstGLE),
"InternetCrackUrl returned %d with GLE=%d (expected to return %d)\n",
569 copy_compsA(&urlSrc, &urlComponents, 32, 1024, 1024, 1024, 0, 1024);
575 "InternetCrackUrl returned %d with GLE=%d (expected to return 0 and ERROR_INVALID_HANDLE or ERROR_INSUFFICIENT_BUFFER)\n",
578 copy_compsA(&urlSrc, &urlComponents, 32, 1024, 1024, 1024, 1024, 0);
584 "InternetCrackUrl returned %d with GLE=%d (expected to return 0 and ERROR_INVALID_HANDLE or ERROR_INSUFFICIENT_BUFFER)\n",
587 copy_compsA(&urlSrc, &urlComponents, 0, 0, 0, 0, 0, 0);
592 "InternetCrackUrl returned %d with GLE=%d (expected to return 0 and ERROR_INVALID_PARAMETER)\n",
595 copy_compsA(&urlSrc, &urlComponents, 32, 1024, 1024, 1024, 1024, 1024);
604 copy_compsA(&urlSrc, &urlComponents, 32, 1024, 1024, 1024, 1024, 1024);
607 ok(
ret ==
FALSE,
"Expected InternetCrackUrl to fail\n");
614 copy_compsA(&urlSrc, &urlComponents, 32, 1024, 1024, 1024, 1024, 1024);
617 ok(
ret ==
FALSE,
"Expected InternetCrackUrl to fail\n");
622 copy_compsA(&urlSrc, &urlComponents, 0, 1024, 1024, 1024, 1024, 1024);
627 ok(
ret ==
FALSE,
"Expected InternetCrackUrl to fail\n");
633 copy_compsA(&urlSrc, &urlComponents, 0, 1024, 1024, 1024, 1024, 1024);
638 ok(
ret ==
FALSE,
"Expected InternetCrackUrl to fail\n");
642 memset(&urlComponents, 0,
sizeof(urlComponents));
646 ok(
ret ==
FALSE,
"Expected InternetCrackUrl to fail\n");
650 memset(&urlComponents, 0,
sizeof(urlComponents));
654 ok(
ret ==
FALSE,
"Expected InternetCrackUrl to fail\n");
661 'h',
't',
't',
'p',
':',
'/',
'/',
'1',
'9',
'2',
'.',
'1',
'6',
'8',
'.',
'0',
'.',
'2',
'2',
'/',
662 'C',
'F',
'I',
'D',
'E',
'/',
'm',
'a',
'i',
'n',
'.',
'c',
'f',
'm',
'?',
'C',
'F',
'S',
'V',
'R',
663 '=',
'I',
'D',
'E',
'&',
'A',
'C',
'T',
'I',
'O',
'N',
'=',
'I',
'D',
'E',
'_',
'D',
'E',
'F',
'A',
665 static const WCHAR url2[] = {
'.',
'.',
'/',
'R',
'i',
't',
'z',
'.',
'x',
'm',
'l',0 };
666 static const WCHAR url3[] = {
'h',
't',
't',
'p',
':',
'/',
'/',
'x',
'.',
'o',
'r',
'g',0 };
678 memset(&comp, 0,
sizeof comp);
698 win_skip(
"InternetCrackUrlW is not implemented\n");
701 ok( !
r,
"InternetCrackUrlW succeeded unexpectedly\n");
704 "expected ERROR_INVALID_PARAMETER got %u\n",
error);
712 ok( !
r,
"InternetCrackUrlW succeeded unexpectedly\n");
717 ok(
r,
"failed to crack url\n");
727 memset(&comp, 0,
sizeof comp);
735 ok(
r,
"failed to crack url\n");
745 memset(&comp, 0,
sizeof comp);
755 ok(
r,
"failed to crack url\n");
769 memset(&comp, 0,
sizeof(comp));
785 ok(!
r,
"InternetCrackUrl should have failed\n");
787 "InternetCrackUrl should have failed with error ERROR_INTERNET_UNRECOGNIZED_SCHEME instead of error %d\n",
797 memset(&comp, 0,
sizeof comp);
812 ok(
r,
"InternetCrackUrlW failed unexpectedly\n");
813 ok(
host[0] ==
'x',
"host should be x.org\n");
814 ok( urlpart[0] == 0,
"urlpart should be empty\n");
818 memset(&comp, 0,
sizeof(comp));
825 ok(
r,
"InternetCrackUrlW failed unexpectedly\n");
827 todo_wine ok(urlpart[0] == 0,
"urlpart should be empty\n");
833 winehq[] =
"www.winehq.org",
836 site_about[] =
"/site/about",
845 lpUrlComponents->
nPort = 80;
866 winehq[] =
"www.winehq.org",
871 site_about[] =
"/site/about",
872 extra_info[] =
"?test=123",
880 ok(!
ret,
"Expected failure\n");
882 "Expected ERROR_INVALID_PARAMETER, got %d\n",
GetLastError());
883 ok(
len == -1,
"Expected len -1, got %d\n",
len);
889 ok(!
ret,
"Expected failure\n");
891 "Expected ERROR_INVALID_PARAMETER, got %d\n",
GetLastError());
892 ok(
len == -1,
"Expected len -1, got %d\n",
len);
898 ok(!
ret,
"Expected failure\n");
900 "Expected ERROR_INVALID_PARAMETER, got %d\n",
GetLastError());
908 ok(!
ret,
"Expected failure\n");
910 "Expected ERROR_INSUFFICIENT_BUFFER, got %d\n",
GetLastError());
911 ok(
len == 51,
"Expected len 51, got %d\n",
len);
917 ok(!
ret,
"Expected failure\n");
919 "Expected ERROR_INSUFFICIENT_BUFFER, got %d\n",
GetLastError());
920 ok(
len == 51,
"Expected len 51, got %d\n",
len);
927 ok(!
ret,
"Expected failure\n");
929 "Expected ERROR_INSUFFICIENT_BUFFER, got %d\n",
GetLastError());
930 ok(
len == 51,
"Expected len 51, got %d\n",
len);
937 ok(
ret,
"Expected success\n");
938 ok(
len == 50,
"Expected len 50, got %d\n",
len);
948 ok(
ret,
"Expected success\n");
949 ok(
len == 50,
"Expected len 50, got %d\n",
len);
955 ok(
ret,
"Expected success\n");
956 ok(
len == 50,
"Expected len 50, got %d\n",
len);
957 ok(
strstr(szUrl,
"80") ==
NULL,
"Didn't expect to find 80 in szUrl\n");
965 ok(
ret,
"Expected success\n");
966 ok(
len == 41,
"Expected len 41, got %d\n",
len);
974 ok(
ret,
"Expected success\n");
975 ok(
len == 50,
"Expected len 50, got %d\n",
len);
986 ok(!
ret,
"Expected failure\n");
988 "Expected ERROR_INVALID_PARAMETER, got %d\n",
GetLastError());
989 ok(
len == 42,
"Expected len 42, got %d\n",
len);
999 ok(
ret,
"Expected success\n");
1000 ok(
len == 50,
"Expected len 50, got %d\n",
len);
1009 ok(
ret,
"Expected success\n");
1010 ok(
len == 32,
"Expected len 32, got %d\n",
len);
1019 ok(
ret,
"Expected success\n");
1020 ok(
len == 50,
"Expected len 50, got %d\n",
len);
1033 ok(
ret,
"Expected success\n");
1044 ok(
ret,
"Expected success\n");
1045 ok(
len == 53,
"Expected len 53, got %d\n",
len);
1046 ok(
strstr(szUrl,
"42") !=
NULL,
"Expected to find 42 in szUrl\n");
1051 memset(&urlComp, 0,
sizeof(urlComp));
1070 ok(
ret,
"Expected success\n");
1076 memset(&urlComp, 0,
sizeof(urlComp));
1083 urlComp.
nPort = 443;
1095 ok(
ret,
"Expected success\n");
1101 memset(&urlComp, 0,
sizeof(urlComp));
1111 ok(
ret,
"Expected success\n");
1117 memset(&urlComp, 0,
sizeof(urlComp));
1126 ok(
ret,
"Expected success\n");
1132 memset(&urlComp, 0,
sizeof(urlComp));
1134 urlComp.
nPort = 8080;
1139 ok(
ret,
"Expected success\n");
1145 memset(&urlComp, 0,
sizeof(urlComp));
1152 urlComp.
nPort = 65535;
1156 ok(
ret,
"Expected success\n");
1162 memset(&urlComp, 0,
sizeof(urlComp));
1176 ok(
ret,
"Expected success\n");
1185 char src[] =
"http://www.winehq.org/%27/ /./>/#> ";
1191 ok(
strcmp(
dst,
"http://www.winehq.org/%27/%20/%3E/#>") == 0,
"Got \"%s\"\n",
dst);
1196 ok(
strcmp(
dst,
"http://www.winehq.org/%27/%20/%3E/#>") == 0,
"Got \"%s\"\n",
dst);
1201 ok(
strcmp(
dst,
"http://www.winehq.org/%27/%20/%3E/#>") == 0,
"Got \"%s\"\n",
dst);
1205 ok(
strcmp(
dst,
"http://www.winehq.org/'/%20/%3E/#>") == 0,
"Got \"%s\"\n",
dst);
1209 ok(
strcmp(
dst,
"http://www.winehq.org/%2527/%20/%3E/#>") == 0,
"Got \"%s\"\n",
dst);
1213 ok(
strcmp(
dst,
"http://www.winehq.org/%27/%20/>/#>") == 0,
"Got \"%s\"\n",
dst);
1217 ok(
strcmp(
dst,
"http://www.winehq.org/%27/ />/#>") == 0,
"Got \"%s\"\n",
dst);
1221 ok(
strcmp(
dst,
"http://www.winehq.org/%27/%20/./%3E/#>") == 0,
"Got \"%s\"\n",
dst);
1229 win_skip(
"Too old IE (older than 6.0)\n");
char * strcat(char *DstString, const char *SrcString)
int strcmp(const char *String1, const char *String2)
char * strstr(char *String1, char *String2)
ACPI_SIZE strlen(const char *String)
char * strcpy(char *DstString, const char *SrcString)
void pwd(int argc, const char *argv[])
void user(int argc, const char *argv[])
#define ERROR_INSUFFICIENT_BUFFER
#define ERROR_CALL_NOT_IMPLEMENTED
#define ERROR_INVALID_PARAMETER
#define GetProcAddress(x, y)
#define HeapFree(x, y, z)
#define ERROR_INVALID_HANDLE
#define MultiByteToWideChar
HMODULE WINAPI DECLSPEC_HOTPATCH GetModuleHandleA(LPCSTR lpModuleName)
int WINAPI lstrcmpW(LPCWSTR str1, LPCWSTR str2)
BOOL WINAPI InternetCanonicalizeUrlA(LPCSTR lpszUrl, LPSTR lpszBuffer, LPDWORD lpdwBufferLength, DWORD dwFlags)
BOOL WINAPI InternetCreateUrlA(LPURL_COMPONENTSA lpUrlComponents, DWORD dwFlags, LPSTR lpszUrl, LPDWORD lpdwUrlLength)
BOOL WINAPI InternetCrackUrlW(const WCHAR *lpszUrl, DWORD dwUrlLength, DWORD dwFlags, URL_COMPONENTSW *lpUC)
BOOL WINAPI InternetCrackUrlA(const char *url, DWORD url_length, DWORD flags, URL_COMPONENTSA *ret_comp)
GLdouble GLdouble GLdouble r
GLboolean GLboolean GLboolean b
GLenum GLuint GLenum GLsizei const GLchar * buf
GLsizei GLenum const GLvoid GLsizei GLenum GLbyte GLbyte GLbyte GLdouble GLdouble GLdouble GLfloat GLfloat GLfloat GLint GLint GLint GLshort GLshort GLshort GLubyte GLubyte GLubyte GLuint GLuint GLuint GLushort GLushort GLushort GLbyte GLbyte GLbyte GLbyte GLdouble GLdouble GLdouble GLdouble GLfloat GLfloat GLfloat GLfloat GLint GLint GLint GLint GLshort GLshort GLshort GLshort GLubyte GLubyte GLubyte GLubyte GLuint GLuint GLuint GLuint GLushort GLushort GLushort GLushort GLboolean const GLdouble const GLfloat const GLint const GLshort const GLbyte const GLdouble const GLfloat const GLint const GLshort const GLdouble const GLfloat const GLint const GLshort const GLdouble const GLfloat const GLint const GLshort const GLdouble const GLfloat const GLint const GLshort const GLdouble const GLdouble const GLfloat const GLfloat const GLint const GLint const GLshort const GLshort const GLdouble const GLfloat const GLint const GLshort const GLdouble const GLfloat const GLint const GLshort const GLdouble const GLfloat const GLint const GLshort const GLdouble const GLfloat const GLint const GLshort const GLdouble const GLfloat const GLint const GLshort const GLdouble const GLfloat const GLint const GLshort const GLdouble const GLfloat const GLint const GLshort GLenum GLenum GLenum GLfloat GLenum GLint GLenum GLenum GLenum GLfloat GLenum GLenum GLint GLenum GLfloat GLenum GLint GLint GLushort GLenum GLenum GLfloat GLenum GLenum GLint GLfloat const GLubyte GLenum GLenum GLenum const GLfloat GLenum GLenum const GLint GLenum GLint GLint GLsizei GLsizei GLint GLenum GLenum const GLvoid GLenum GLenum const GLfloat GLenum GLenum const GLint GLenum GLenum const GLdouble GLenum GLenum const GLfloat GLenum GLenum const GLint GLsizei GLuint GLfloat GLuint GLbitfield GLfloat GLint GLuint GLboolean GLenum GLfloat GLenum GLbitfield GLenum GLfloat GLfloat GLint GLint const GLfloat GLenum GLfloat GLfloat GLint GLint GLfloat GLfloat GLint GLint const GLfloat GLint GLfloat GLfloat GLint GLfloat GLfloat GLint GLfloat GLfloat const GLdouble const GLfloat const GLdouble const GLfloat GLint i
int WINAPI lstrlenA(LPCSTR lpString)
static const BYTE localhost[]
static const WCHAR url2[]
static void fill_url_components(URL_COMPONENTS *uc)
static const WCHAR url3[]
static void zero_compsA(URL_COMPONENTSA *dst, DWORD scheLen, DWORD hostLen, DWORD userLen, DWORD passLen, DWORD pathLen, DWORD extrLen)
static int strcmp_wa(const WCHAR *str1, const char *str2)
static void copy_compsA(URL_COMPONENTSA *src, URL_COMPONENTSA *dst, DWORD scheLen, DWORD hostLen, DWORD userLen, DWORD passLen, DWORD pathLen, DWORD extrLen)
static void InternetCrackUrlW_test(void)
static const crack_url_test_t crack_url_tests[]
static void test_crack_url(const crack_url_test_t *test)
static void InternetCreateUrlA_test(void)
static void InternetCrackUrl_test(void)
static WCHAR * a2w(const char *str)
static void test_long_url(void)
static void InternetCanonicalizeUrl_test(void)
const char * exp_hostname
const char * exp_username
const char * exp_extrainfo
const char * exp_password
DWORD WINAPI GetLastError(void)
#define ICU_ENCODE_SPACES_ONLY
#define INTERNET_SCHEME_HTTP
#define ICU_ENCODE_PERCENT
@ INTERNET_SCHEME_UNKNOWN
#define ERROR_INTERNET_UNRECOGNIZED_SCHEME
static const WCHAR userName[]