Skip to content
Projects
Groups
Snippets
Help
This project
Loading...
Sign in / Register
Toggle navigation
W
wine-winehq
Project
Project
Details
Activity
Cycle Analytics
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Issues
0
Issues
0
List
Board
Labels
Milestones
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Charts
Registry
Registry
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
wine
wine-winehq
Commits
62337044
Commit
62337044
authored
Jun 23, 2008
by
Hans Leidekker
Committed by
Alexandre Julliard
Jun 24, 2008
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
wininet: Resolve hostname once per connection.
parent
34ff555c
Hide whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
7 additions
and
24 deletions
+7
-24
http.c
dlls/wininet/http.c
+3
-10
http.c
dlls/wininet/tests/http.c
+4
-14
No files found.
dlls/wininet/http.c
View file @
62337044
...
...
@@ -1329,6 +1329,8 @@ static BOOL HTTP_ResolveName(LPWININETHTTPREQW lpwhr)
char
szaddr
[
32
];
LPWININETHTTPSESSIONW
lpwhs
=
lpwhr
->
lpHttpSession
;
if
(
lpwhs
->
socketAddress
.
sin_addr
.
s_addr
)
return
TRUE
;
INTERNET_SendCallback
(
&
lpwhr
->
hdr
,
lpwhr
->
hdr
.
dwContext
,
INTERNET_STATUS_RESOLVING_NAME
,
lpwhs
->
lpszServerName
,
...
...
@@ -2016,16 +2018,6 @@ HINTERNET WINAPI HTTP_HttpOpenRequestW(LPWININETHTTPSESSIONW lpwhs,
INTERNET_STATUS_HANDLE_CREATED
,
&
handle
,
sizeof
(
handle
));
/*
* A STATUS_REQUEST_COMPLETE is NOT sent here as per my tests on windows
*/
if
(
!
HTTP_ResolveName
(
lpwhr
))
{
InternetCloseHandle
(
handle
);
handle
=
NULL
;
}
lend:
if
(
lpwhr
)
WININET_Release
(
&
lpwhr
->
hdr
);
...
...
@@ -3600,6 +3592,7 @@ static BOOL HTTP_OpenConnection(LPWININETHTTPREQW lpwhr)
bSuccess
=
TRUE
;
goto
lend
;
}
if
(
!
HTTP_ResolveName
(
lpwhr
))
goto
lend
;
lpwhs
=
lpwhr
->
lpHttpSession
;
...
...
dlls/wininet/tests/http.c
View file @
62337044
...
...
@@ -270,8 +270,6 @@ static void InternetReadFile_test(int flags)
CHECK_NOTIFIED
(
INTERNET_STATUS_HANDLE_CREATED
);
SET_EXPECT
(
INTERNET_STATUS_HANDLE_CREATED
);
SET_WINE_ALLOW
(
INTERNET_STATUS_RESOLVING_NAME
);
SET_WINE_ALLOW
(
INTERNET_STATUS_NAME_RESOLVED
);
trace
(
"HttpOpenRequestA <--
\n
"
);
hor
=
HttpOpenRequestA
(
hic
,
"GET"
,
"/about/"
,
NULL
,
NULL
,
types
,
...
...
@@ -297,11 +295,8 @@ static void InternetReadFile_test(int flags)
ok
(
!
strcmp
(
buffer
,
"http://www.winehq.org/about/"
),
"Wrong URL %s
\n
"
,
buffer
);
CHECK_NOTIFIED
(
INTERNET_STATUS_HANDLE_CREATED
);
todo_wine
{
CHECK_NOT_NOTIFIED
(
INTERNET_STATUS_RESOLVING_NAME
);
CHECK_NOT_NOTIFIED
(
INTERNET_STATUS_NAME_RESOLVED
);
}
CHECK_NOT_NOTIFIED
(
INTERNET_STATUS_RESOLVING_NAME
);
CHECK_NOT_NOTIFIED
(
INTERNET_STATUS_NAME_RESOLVED
);
if
(
first_connection_to_test_url
)
{
SET_EXPECT
(
INTERNET_STATUS_RESOLVING_NAME
);
...
...
@@ -516,8 +511,6 @@ static void InternetReadFileExA_test(int flags)
CHECK_NOTIFIED
(
INTERNET_STATUS_HANDLE_CREATED
);
SET_EXPECT
(
INTERNET_STATUS_HANDLE_CREATED
);
SET_WINE_ALLOW
(
INTERNET_STATUS_RESOLVING_NAME
);
SET_WINE_ALLOW
(
INTERNET_STATUS_NAME_RESOLVED
);
trace
(
"HttpOpenRequestA <--
\n
"
);
hor
=
HttpOpenRequestA
(
hic
,
"GET"
,
"/about/"
,
NULL
,
NULL
,
types
,
...
...
@@ -538,11 +531,8 @@ static void InternetReadFileExA_test(int flags)
if
(
hor
==
0x0
)
goto
abort
;
CHECK_NOTIFIED
(
INTERNET_STATUS_HANDLE_CREATED
);
todo_wine
{
CHECK_NOT_NOTIFIED
(
INTERNET_STATUS_RESOLVING_NAME
);
CHECK_NOT_NOTIFIED
(
INTERNET_STATUS_NAME_RESOLVED
);
}
CHECK_NOT_NOTIFIED
(
INTERNET_STATUS_RESOLVING_NAME
);
CHECK_NOT_NOTIFIED
(
INTERNET_STATUS_NAME_RESOLVED
);
if
(
first_connection_to_test_url
)
{
SET_EXPECT
(
INTERNET_STATUS_RESOLVING_NAME
);
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment