Skip to content
Projects
Groups
Snippets
Help
This project
Loading...
Sign in / Register
Toggle navigation
W
wine-cw
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-cw
Commits
848cd8a2
Commit
848cd8a2
authored
Jan 13, 2012
by
Hans Leidekker
Committed by
Alexandre Julliard
Jan 16, 2012
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
wininet: Add support for setting and retrieving the connect timeout.
parent
72273a07
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
30 additions
and
0 deletions
+30
-0
http.c
dlls/wininet/http.c
+30
-0
No files found.
dlls/wininet/http.c
View file @
848cd8a2
...
...
@@ -2151,6 +2151,13 @@ static DWORD HTTPREQ_QueryOption(object_header_t *hdr, DWORD option, void *buffe
return
ERROR_SUCCESS
;
}
}
case
INTERNET_OPTION_CONNECT_TIMEOUT
:
if
(
*
size
<
sizeof
(
DWORD
))
return
ERROR_INSUFFICIENT_BUFFER
;
*
size
=
sizeof
(
DWORD
);
*
(
DWORD
*
)
buffer
=
req
->
connect_timeout
;
return
ERROR_SUCCESS
;
}
return
INET_QueryOption
(
hdr
,
option
,
buffer
,
size
,
unicode
);
...
...
@@ -2174,6 +2181,13 @@ static DWORD HTTPREQ_SetOption(object_header_t *hdr, DWORD option, void *buffer,
req
->
netconn
->
security_flags
=
flags
;
return
ERROR_SUCCESS
;
}
case
INTERNET_OPTION_CONNECT_TIMEOUT
:
if
(
size
!=
sizeof
(
DWORD
))
return
ERROR_INVALID_PARAMETER
;
req
->
connect_timeout
=
*
(
DWORD
*
)
buffer
;
return
ERROR_SUCCESS
;
case
INTERNET_OPTION_SEND_TIMEOUT
:
case
INTERNET_OPTION_RECEIVE_TIMEOUT
:
TRACE
(
"INTERNET_OPTION_SEND/RECEIVE_TIMEOUT
\n
"
);
...
...
@@ -5438,6 +5452,8 @@ static void HTTPSESSION_Destroy(object_header_t *hdr)
static
DWORD
HTTPSESSION_QueryOption
(
object_header_t
*
hdr
,
DWORD
option
,
void
*
buffer
,
DWORD
*
size
,
BOOL
unicode
)
{
http_session_t
*
ses
=
(
http_session_t
*
)
hdr
;
switch
(
option
)
{
case
INTERNET_OPTION_HANDLE_TYPE
:
TRACE
(
"INTERNET_OPTION_HANDLE_TYPE
\n
"
);
...
...
@@ -5448,6 +5464,15 @@ static DWORD HTTPSESSION_QueryOption(object_header_t *hdr, DWORD option, void *b
*
size
=
sizeof
(
DWORD
);
*
(
DWORD
*
)
buffer
=
INTERNET_HANDLE_TYPE_CONNECT_HTTP
;
return
ERROR_SUCCESS
;
case
INTERNET_OPTION_CONNECT_TIMEOUT
:
TRACE
(
"INTERNET_OPTION_CONNECT_TIMEOUT
\n
"
);
if
(
*
size
<
sizeof
(
DWORD
))
return
ERROR_INSUFFICIENT_BUFFER
;
*
size
=
sizeof
(
DWORD
);
*
(
DWORD
*
)
buffer
=
ses
->
connect_timeout
;
return
ERROR_SUCCESS
;
}
return
INET_QueryOption
(
hdr
,
option
,
buffer
,
size
,
unicode
);
...
...
@@ -5470,6 +5495,11 @@ static DWORD HTTPSESSION_SetOption(object_header_t *hdr, DWORD option, void *buf
if
(
!
(
ses
->
password
=
heap_strdupW
(
buffer
)))
return
ERROR_OUTOFMEMORY
;
return
ERROR_SUCCESS
;
}
case
INTERNET_OPTION_CONNECT_TIMEOUT
:
{
ses
->
connect_timeout
=
*
(
DWORD
*
)
buffer
;
return
ERROR_SUCCESS
;
}
default:
break
;
}
...
...
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