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
9fe90053
Commit
9fe90053
authored
Mar 20, 2020
by
Jacek Caban
Committed by
Alexandre Julliard
Mar 20, 2020
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
wininet: Use _ltow instead of sprintf for port number in InternetCreateUrl.
Signed-off-by:
Jacek Caban
<
jacek@codeweavers.com
>
Signed-off-by:
Alexandre Julliard
<
julliard@winehq.org
>
parent
2be65404
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
6 additions
and
7 deletions
+6
-7
internet.c
dlls/wininet/internet.c
+6
-7
No files found.
dlls/wininet/internet.c
View file @
9fe90053
...
...
@@ -4263,9 +4263,10 @@ static BOOL calc_url_length(LPURL_COMPONENTSW lpUrlComponents,
if
(
!
url_uses_default_port
(
nScheme
,
lpUrlComponents
->
nPort
))
{
char
szPort
[
MAX_WORD_DIGITS
+
1
];
WCHAR
port
[
MAX_WORD_DIGITS
+
1
];
*
lpdwUrlLength
+=
sprintf
(
szPort
,
"%d"
,
lpUrlComponents
->
nPort
);
_ltow
(
lpUrlComponents
->
nPort
,
port
,
10
);
*
lpdwUrlLength
+=
lstrlenW
(
port
);
*
lpdwUrlLength
+=
strlen
(
":"
);
}
...
...
@@ -4421,10 +4422,8 @@ BOOL WINAPI InternetCreateUrlW(LPURL_COMPONENTSW lpUrlComponents, DWORD dwFlags,
{
DWORD
dwLen
;
INTERNET_SCHEME
nScheme
;
WCHAR
*
start
=
lpszUrl
;
static
const
WCHAR
slashSlashW
[]
=
{
'/'
,
'/'
};
static
const
WCHAR
fmtW
[]
=
{
'%'
,
'u'
,
0
};
TRACE
(
"(%p,%d,%p,%p)
\n
"
,
lpUrlComponents
,
dwFlags
,
lpszUrl
,
lpdwUrlLength
);
...
...
@@ -4509,9 +4508,9 @@ BOOL WINAPI InternetCreateUrlW(LPURL_COMPONENTSW lpUrlComponents, DWORD dwFlags,
if
(
!
url_uses_default_port
(
nScheme
,
lpUrlComponents
->
nPort
))
{
*
lpszUrl
=
':'
;
lpszUrl
++
;
lpszUrl
+=
swprintf
(
lpszUrl
,
*
lpdwUrlLength
-
(
lpszUrl
-
start
),
fmtW
,
lpUrlComponents
->
nPort
);
*
lpszUrl
++
=
':'
;
_ltow
(
lpUrlComponents
->
nPort
,
lpszUrl
,
10
)
;
lpszUrl
+=
lstrlenW
(
lpszUrl
);
}
/* add slash between hostname and path if necessary */
...
...
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