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
7d26ac01
Commit
7d26ac01
authored
Nov 01, 2020
by
Michael Stefaniuc
Committed by
Alexandre Julliard
Nov 02, 2020
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
appwiz.cpl: Use zero terminated wide-char strings.
Signed-off-by:
Michael Stefaniuc
<
mstefani@winehq.org
>
Signed-off-by:
Alexandre Julliard
<
julliard@winehq.org
>
parent
dcf7a1f6
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
6 additions
and
9 deletions
+6
-9
addons.c
dlls/appwiz.cpl/addons.c
+6
-9
No files found.
dlls/appwiz.cpl/addons.c
View file @
7d26ac01
...
...
@@ -598,21 +598,18 @@ static IInternetBindInfo InstallCallbackBindInfo = { &InstallCallbackBindInfoVtb
static
void
append_url_params
(
WCHAR
*
url
)
{
static
const
WCHAR
arch_formatW
[]
=
{
'?'
,
'a'
,
'r'
,
'c'
,
'h'
,
'='
};
static
const
WCHAR
v_formatW
[]
=
{
'&'
,
'v'
,
'='
};
static
const
WCHAR
winevW
[]
=
{
'&'
,
'w'
,
'i'
,
'n'
,
'e'
,
'v'
,
'='
};
DWORD
size
=
INTERNET_MAX_URL_LENGTH
*
sizeof
(
WCHAR
);
DWORD
len
=
lstrlenW
(
url
);
memcpy
(
url
+
len
,
arch_formatW
,
sizeof
(
arch_formatW
)
);
len
+=
ARRAY_SIZE
(
arch_formatW
);
lstrcpyW
(
url
+
len
,
L"?arch="
);
len
+=
lstrlenW
(
L"?arch="
);
len
+=
MultiByteToWideChar
(
CP_ACP
,
0
,
GECKO_ARCH
,
sizeof
(
GECKO_ARCH
),
url
+
len
,
size
/
sizeof
(
WCHAR
)
-
len
)
-
1
;
memcpy
(
url
+
len
,
v_formatW
,
sizeof
(
v_formatW
)
);
len
+=
ARRAY_SIZE
(
v_formatW
);
lstrcpyW
(
url
+
len
,
L"&v="
);
len
+=
lstrlenW
(
L"&v="
);
len
+=
MultiByteToWideChar
(
CP_ACP
,
0
,
addon
->
version
,
-
1
,
url
+
len
,
size
/
sizeof
(
WCHAR
)
-
len
)
-
1
;
memcpy
(
url
+
len
,
winevW
,
sizeof
(
winevW
)
);
len
+=
ARRAY_SIZE
(
winevW
);
lstrcpyW
(
url
+
len
,
L"&winev="
);
len
+=
lstrlenW
(
L"&winev="
);
MultiByteToWideChar
(
CP_ACP
,
0
,
wine_get_version
(),
-
1
,
url
+
len
,
size
/
sizeof
(
WCHAR
)
-
len
);
}
...
...
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