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
71288ba5
Commit
71288ba5
authored
Jan 28, 2022
by
Esme Povirk
Committed by
Alexandre Julliard
Jan 31, 2022
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
mscoree: Use wide string syntax in create_monodata.
Signed-off-by:
Esme Povirk
<
esme@codeweavers.com
>
Signed-off-by:
Alexandre Julliard
<
julliard@winehq.org
>
parent
17b34ca8
Show whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
8 additions
and
12 deletions
+8
-12
corruntimehost.c
dlls/mscoree/corruntimehost.c
+8
-12
No files found.
dlls/mscoree/corruntimehost.c
View file @
71288ba5
...
...
@@ -1718,13 +1718,9 @@ end:
HRESULT
create_monodata
(
REFIID
riid
,
LPVOID
*
ppObj
)
{
static
const
WCHAR
wszAssembly
[]
=
{
'A'
,
's'
,
's'
,
'e'
,
'm'
,
'b'
,
'l'
,
'y'
,
0
};
static
const
WCHAR
wszCodebase
[]
=
{
'C'
,
'o'
,
'd'
,
'e'
,
'B'
,
'a'
,
's'
,
'e'
,
0
};
static
const
WCHAR
wszClass
[]
=
{
'C'
,
'l'
,
'a'
,
's'
,
's'
,
0
};
static
const
WCHAR
wszFileSlash
[]
=
{
'f'
,
'i'
,
'l'
,
'e'
,
':'
,
'/'
,
'/'
,
'/'
,
0
};
static
const
WCHAR
wszCLSIDSlash
[]
=
{
'C'
,
'L'
,
'S'
,
'I'
,
'D'
,
'\\'
,
0
};
static
const
WCHAR
wszInprocServer32
[]
=
{
'\\'
,
'I'
,
'n'
,
'p'
,
'r'
,
'o'
,
'c'
,
'S'
,
'e'
,
'r'
,
'v'
,
'e'
,
'r'
,
'3'
,
'2'
,
0
};
static
const
WCHAR
wszDLL
[]
=
{
'.'
,
'd'
,
'l'
,
'l'
,
0
};
static
const
WCHAR
wszFileSlash
[]
=
L"file:///"
;
static
const
WCHAR
wszCLSIDSlash
[]
=
L"CLSID
\\
"
;
static
const
WCHAR
wszInprocServer32
[]
=
L"
\\
InprocServer32"
;
WCHAR
path
[
CHARS_IN_GUID
+
ARRAY_SIZE
(
wszCLSIDSlash
)
+
ARRAY_SIZE
(
wszInprocServer32
)
-
1
];
MonoDomain
*
domain
;
MonoAssembly
*
assembly
;
...
...
@@ -1751,7 +1747,7 @@ HRESULT create_monodata(REFIID riid, LPVOID *ppObj )
res
=
RegOpenKeyExW
(
HKEY_CLASSES_ROOT
,
path
,
0
,
KEY_READ
,
&
key
);
if
(
res
!=
ERROR_FILE_NOT_FOUND
)
{
res
=
RegGetValueW
(
key
,
NULL
,
wszClass
,
RRF_RT_REG_SZ
,
NULL
,
classname
,
&
dwBufLen
);
res
=
RegGetValueW
(
key
,
NULL
,
L"Class"
,
RRF_RT_REG_SZ
,
NULL
,
classname
,
&
dwBufLen
);
if
(
res
!=
ERROR_SUCCESS
)
{
WARN
(
"Class value cannot be found.
\n
"
);
...
...
@@ -1762,7 +1758,7 @@ HRESULT create_monodata(REFIID riid, LPVOID *ppObj )
TRACE
(
"classname (%s)
\n
"
,
debugstr_w
(
classname
));
dwBufLen
=
MAX_PATH
+
8
;
res
=
RegGetValueW
(
key
,
NULL
,
wszCodebase
,
RRF_RT_REG_SZ
,
NULL
,
codebase
,
&
dwBufLen
);
res
=
RegGetValueW
(
key
,
NULL
,
L"CodeBase"
,
RRF_RT_REG_SZ
,
NULL
,
codebase
,
&
dwBufLen
);
if
(
res
==
ERROR_SUCCESS
)
{
/* Strip file:/// */
...
...
@@ -1797,7 +1793,7 @@ HRESULT create_monodata(REFIID riid, LPVOID *ppObj )
if
(
res
!=
ERROR_SUCCESS
)
goto
cleanup
;
dwBufLen
=
MAX_PATH
+
8
;
res
=
RegGetValueW
(
subkey
,
NULL
,
wszAssembly
,
RRF_RT_REG_SZ
,
NULL
,
assemblyname
,
&
dwBufLen
);
res
=
RegGetValueW
(
subkey
,
NULL
,
L"Assembly"
,
RRF_RT_REG_SZ
,
NULL
,
assemblyname
,
&
dwBufLen
);
RegCloseKey
(
subkey
);
if
(
res
!=
ERROR_SUCCESS
)
goto
cleanup
;
...
...
@@ -1805,7 +1801,7 @@ HRESULT create_monodata(REFIID riid, LPVOID *ppObj )
else
{
dwBufLen
=
MAX_PATH
+
8
;
res
=
RegGetValueW
(
key
,
NULL
,
wszAssembly
,
RRF_RT_REG_SZ
,
NULL
,
assemblyname
,
&
dwBufLen
);
res
=
RegGetValueW
(
key
,
NULL
,
L"Assembly"
,
RRF_RT_REG_SZ
,
NULL
,
assemblyname
,
&
dwBufLen
);
if
(
res
!=
ERROR_SUCCESS
)
goto
cleanup
;
}
...
...
@@ -1830,7 +1826,7 @@ HRESULT create_monodata(REFIID riid, LPVOID *ppObj )
*
(
ns
)
=
'\0'
;
lstrcatW
(
filename
,
assemblyname
);
*
(
ns
)
=
'.'
;
lstrcatW
(
filename
,
wszDLL
);
lstrcatW
(
filename
,
L".dll"
);
}
}
}
...
...
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