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
a4d0abb2
Commit
a4d0abb2
authored
Sep 07, 2008
by
Hans Leidekker
Committed by
Alexandre Julliard
Sep 08, 2008
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
winhttp: Add the remaining completion notifications.
parent
2fb74678
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
33 additions
and
0 deletions
+33
-0
request.c
dlls/winhttp/request.c
+33
-0
No files found.
dlls/winhttp/request.c
View file @
a4d0abb2
...
...
@@ -1190,6 +1190,17 @@ BOOL WINAPI WinHttpQueryDataAvailable( HINTERNET hrequest, LPDWORD available )
ret
=
netconn_query_data_available
(
&
request
->
netconn
,
&
num_bytes
);
if
(
request
->
connect
->
hdr
.
flags
&
WINHTTP_FLAG_ASYNC
)
{
if
(
ret
)
send_callback
(
&
request
->
hdr
,
WINHTTP_CALLBACK_STATUS_DATA_AVAILABLE
,
&
num_bytes
,
sizeof
(
DWORD
)
);
else
{
WINHTTP_ASYNC_RESULT
async
;
async
.
dwResult
=
API_QUERY_DATA_AVAILABLE
;
async
.
dwError
=
get_last_error
();
send_callback
(
&
request
->
hdr
,
WINHTTP_CALLBACK_STATUS_REQUEST_ERROR
,
&
async
,
sizeof
(
async
)
);
}
}
if
(
ret
&&
available
)
*
available
=
num_bytes
;
release_object
(
&
request
->
hdr
);
return
ret
;
...
...
@@ -1304,6 +1315,17 @@ BOOL WINAPI WinHttpReadData( HINTERNET hrequest, LPVOID buffer, DWORD to_read, L
else
ret
=
read_data
(
request
,
buffer
,
to_read
,
&
num_bytes
,
async
);
if
(
async
)
{
if
(
ret
)
send_callback
(
&
request
->
hdr
,
WINHTTP_CALLBACK_STATUS_READ_COMPLETE
,
buffer
,
num_bytes
);
else
{
WINHTTP_ASYNC_RESULT
async
;
async
.
dwResult
=
API_READ_DATA
;
async
.
dwError
=
get_last_error
();
send_callback
(
&
request
->
hdr
,
WINHTTP_CALLBACK_STATUS_REQUEST_ERROR
,
&
async
,
sizeof
(
async
)
);
}
}
if
(
ret
&&
read
)
*
read
=
num_bytes
;
release_object
(
&
request
->
hdr
);
return
ret
;
...
...
@@ -1334,6 +1356,17 @@ BOOL WINAPI WinHttpWriteData( HINTERNET hrequest, LPCVOID buffer, DWORD to_write
ret
=
netconn_send
(
&
request
->
netconn
,
buffer
,
to_write
,
0
,
&
num_bytes
);
if
(
request
->
connect
->
hdr
.
flags
&
WINHTTP_FLAG_ASYNC
)
{
if
(
ret
)
send_callback
(
&
request
->
hdr
,
WINHTTP_CALLBACK_FLAG_WRITE_COMPLETE
,
&
num_bytes
,
sizeof
(
DWORD
)
);
else
{
WINHTTP_ASYNC_RESULT
async
;
async
.
dwResult
=
API_WRITE_DATA
;
async
.
dwError
=
get_last_error
();
send_callback
(
&
request
->
hdr
,
WINHTTP_CALLBACK_STATUS_REQUEST_ERROR
,
&
async
,
sizeof
(
async
)
);
}
}
if
(
ret
&&
written
)
*
written
=
num_bytes
;
release_object
(
&
request
->
hdr
);
return
ret
;
...
...
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