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
4615b1c0
Commit
4615b1c0
authored
Oct 17, 2008
by
Hans Leidekker
Committed by
Alexandre Julliard
Oct 17, 2008
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
wininet: Fix buffer size query for InternetQueryOption(INTERNET_OPTION_PROXY).
parent
1b5e84a5
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
7 additions
and
3 deletions
+7
-3
internet.c
dlls/wininet/internet.c
+7
-3
No files found.
dlls/wininet/internet.c
View file @
4615b1c0
...
...
@@ -546,8 +546,10 @@ static DWORD APPINFO_QueryOption(WININETHANDLEHEADER *hdr, DWORD option, void *b
if
(
ai
->
lpszProxyBypass
)
proxyBypassBytesRequired
=
(
lstrlenW
(
ai
->
lpszProxyBypass
)
+
1
)
*
sizeof
(
WCHAR
);
if
(
*
size
<
sizeof
(
INTERNET_PROXY_INFOW
)
+
proxyBytesRequired
+
proxyBypassBytesRequired
)
return
ERROR_INSUFFICIENT_BUFFER
;
{
*
size
=
sizeof
(
INTERNET_PROXY_INFOW
)
+
proxyBytesRequired
+
proxyBypassBytesRequired
;
return
ERROR_INSUFFICIENT_BUFFER
;
}
proxy
=
(
LPWSTR
)((
LPBYTE
)
buffer
+
sizeof
(
INTERNET_PROXY_INFOW
));
proxy_bypass
=
(
LPWSTR
)((
LPBYTE
)
buffer
+
sizeof
(
INTERNET_PROXY_INFOW
)
+
proxyBytesRequired
);
...
...
@@ -577,8 +579,10 @@ static DWORD APPINFO_QueryOption(WININETHANDLEHEADER *hdr, DWORD option, void *b
proxyBypassBytesRequired
=
WideCharToMultiByte
(
CP_ACP
,
0
,
ai
->
lpszProxyBypass
,
-
1
,
NULL
,
0
,
NULL
,
NULL
);
if
(
*
size
<
sizeof
(
INTERNET_PROXY_INFOA
)
+
proxyBytesRequired
+
proxyBypassBytesRequired
)
{
*
size
=
sizeof
(
INTERNET_PROXY_INFOA
)
+
proxyBytesRequired
+
proxyBypassBytesRequired
;
return
ERROR_INSUFFICIENT_BUFFER
;
}
proxy
=
(
LPSTR
)((
LPBYTE
)
buffer
+
sizeof
(
INTERNET_PROXY_INFOA
));
proxy_bypass
=
(
LPSTR
)((
LPBYTE
)
buffer
+
sizeof
(
INTERNET_PROXY_INFOA
)
+
proxyBytesRequired
);
...
...
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