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
9d55252d
Commit
9d55252d
authored
May 31, 2008
by
Hans Leidekker
Committed by
Alexandre Julliard
Jun 02, 2008
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
wininet: Don't send a handle closing callback for session handles created with InternetOpenUrl.
parent
2f99450c
Show whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
19 additions
and
5 deletions
+19
-5
internet.c
dlls/wininet/internet.c
+4
-0
http.c
dlls/wininet/tests/http.c
+15
-5
No files found.
dlls/wininet/internet.c
View file @
9d55252d
...
@@ -181,9 +181,13 @@ BOOL WININET_Release( LPWININETHANDLEHEADER info )
...
@@ -181,9 +181,13 @@ BOOL WININET_Release( LPWININETHANDLEHEADER info )
TRACE
(
"closing connection %p
\n
"
,
info
);
TRACE
(
"closing connection %p
\n
"
,
info
);
info
->
vtbl
->
CloseConnection
(
info
);
info
->
vtbl
->
CloseConnection
(
info
);
}
}
/* Don't send a callback if this is a session handle created with InternetOpenUrl */
if
(
info
->
htype
!=
WH_HHTTPSESSION
||
!
(
info
->
dwInternalFlags
&
INET_OPENURL
))
{
INTERNET_SendCallback
(
info
,
info
->
dwContext
,
INTERNET_SendCallback
(
info
,
info
->
dwContext
,
INTERNET_STATUS_HANDLE_CLOSING
,
&
info
->
hInternet
,
INTERNET_STATUS_HANDLE_CLOSING
,
&
info
->
hInternet
,
sizeof
(
HINTERNET
));
sizeof
(
HINTERNET
));
}
TRACE
(
"destroying object %p
\n
"
,
info
);
TRACE
(
"destroying object %p
\n
"
,
info
);
if
(
info
->
htype
!=
WH_HINIT
)
if
(
info
->
htype
!=
WH_HINIT
)
list_remove
(
&
info
->
entry
);
list_remove
(
&
info
->
entry
);
...
...
dlls/wininet/tests/http.c
View file @
9d55252d
...
@@ -1809,18 +1809,25 @@ struct context
...
@@ -1809,18 +1809,25 @@ struct context
static
void
WINAPI
cb
(
HINTERNET
handle
,
DWORD_PTR
context
,
DWORD
status
,
LPVOID
info
,
DWORD
size
)
static
void
WINAPI
cb
(
HINTERNET
handle
,
DWORD_PTR
context
,
DWORD
status
,
LPVOID
info
,
DWORD
size
)
{
{
INTERNET_ASYNC_RESULT
*
result
=
info
;
struct
context
*
ctx
=
(
struct
context
*
)
context
;
trace
(
"%p 0x%08lx %u %p 0x%08x
\n
"
,
handle
,
context
,
status
,
info
,
size
);
trace
(
"%p 0x%08lx %u %p 0x%08x
\n
"
,
handle
,
context
,
status
,
info
,
size
);
if
(
status
==
INTERNET_STATUS_REQUEST_COMPLETE
)
if
(
status
==
INTERNET_STATUS_REQUEST_COMPLETE
)
{
{
INTERNET_ASYNC_RESULT
*
result
=
info
;
struct
context
*
ctx
=
(
struct
context
*
)
context
;
trace
(
"request handle: 0x%08lx
\n
"
,
result
->
dwResult
);
trace
(
"request handle: 0x%08lx
\n
"
,
result
->
dwResult
);
ctx
->
req
=
(
HINTERNET
)
result
->
dwResult
;
ctx
->
req
=
(
HINTERNET
)
result
->
dwResult
;
SetEvent
(
ctx
->
event
);
SetEvent
(
ctx
->
event
);
}
}
if
(
status
==
INTERNET_STATUS_HANDLE_CLOSING
)
{
DWORD
type
=
INTERNET_HANDLE_TYPE_CONNECT_HTTP
,
size
=
sizeof
(
type
);
if
(
InternetQueryOption
(
handle
,
INTERNET_OPTION_HANDLE_TYPE
,
&
type
,
&
size
))
ok
(
type
!=
INTERNET_HANDLE_TYPE_CONNECT_HTTP
,
"unexpected callback
\n
"
);
SetEvent
(
ctx
->
event
);
}
}
}
static
void
test_open_url_async
(
void
)
static
void
test_open_url_async
(
void
)
...
@@ -1857,9 +1864,12 @@ static void test_open_url_async(void)
...
@@ -1857,9 +1864,12 @@ static void test_open_url_async(void)
ok
(
!
ret
&&
GetLastError
()
==
ERROR_INSUFFICIENT_BUFFER
,
"HttpQueryInfo failed
\n
"
);
ok
(
!
ret
&&
GetLastError
()
==
ERROR_INSUFFICIENT_BUFFER
,
"HttpQueryInfo failed
\n
"
);
ok
(
size
>
0
,
"expected size > 0
\n
"
);
ok
(
size
>
0
,
"expected size > 0
\n
"
);
CloseHandle
(
ctx
.
event
);
ResetEvent
(
ctx
.
event
);
InternetCloseHandle
(
ctx
.
req
);
InternetCloseHandle
(
ctx
.
req
);
WaitForSingleObject
(
ctx
.
event
,
INFINITE
);
InternetCloseHandle
(
ses
);
InternetCloseHandle
(
ses
);
CloseHandle
(
ctx
.
event
);
}
}
#define STATUS_STRING(status) \
#define STATUS_STRING(status) \
...
...
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