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
a3a19518
Commit
a3a19518
authored
Aug 14, 2013
by
Alistair Leslie-Hughes
Committed by
Alexandre Julliard
Nov 20, 2013
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
mscoree: Attempt to load the assembly from the application directory.
parent
0ff0a6e9
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
27 additions
and
4 deletions
+27
-4
corruntimehost.c
dlls/mscoree/corruntimehost.c
+27
-4
No files found.
dlls/mscoree/corruntimehost.c
View file @
a3a19518
...
...
@@ -1280,6 +1280,7 @@ HRESULT create_monodata(REFIID riid, LPVOID *ppObj )
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
};
WCHAR
path
[
CHARS_IN_GUID
+
ARRAYSIZE
(
wszCLSIDSlash
)
+
ARRAYSIZE
(
wszInprocServer32
)
-
1
];
MonoDomain
*
domain
;
MonoAssembly
*
assembly
;
...
...
@@ -1328,6 +1329,8 @@ HRESULT create_monodata(REFIID riid, LPVOID *ppObj )
}
else
{
WCHAR
assemblyname
[
MAX_PATH
+
8
];
hr
=
CLASS_E_CLASSNOTAVAILABLE
;
WARN
(
"CodeBase value cannot be found, trying Assembly.
\n
"
);
/* get the last subkey of InprocServer32 */
...
...
@@ -1343,16 +1346,36 @@ 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
,
codebas
e
,
&
dwBufLen
);
res
=
RegGetValueW
(
subkey
,
NULL
,
wszAssembly
,
RRF_RT_REG_SZ
,
NULL
,
assemblynam
e
,
&
dwBufLen
);
RegCloseKey
(
subkey
);
if
(
res
!=
ERROR_SUCCESS
)
goto
cleanup
;
hr
=
get_file_from_strongname
(
codebase
,
filename
,
MAX_PATH
);
hr
=
get_file_from_strongname
(
assemblyname
,
filename
,
MAX_PATH
);
if
(
!
SUCCEEDED
(
hr
))
goto
cleanup
;
{
/*
* The registry doesn't have a CodeBase entry and it's not in the GAC.
*
* Use the Assembly Key to retrieve the filename.
* Assembly : REG_SZ : AssemblyName, Version=X.X.X.X, Culture=neutral, PublicKeyToken=null
*/
WCHAR
*
ns
;
WARN
(
"Attempt to load from the application directory.
\n
"
);
GetModuleFileNameW
(
NULL
,
filename
,
MAX_PATH
);
ns
=
strrchrW
(
filename
,
'\\'
);
*
(
ns
+
1
)
=
'\0'
;
ns
=
strchrW
(
assemblyname
,
','
);
*
(
ns
)
=
'\0'
;
strcatW
(
filename
,
assemblyname
);
*
(
ns
)
=
'.'
;
strcatW
(
filename
,
wszDLL
);
}
}
TRACE
(
"
codebas
e (%s)
\n
"
,
debugstr_w
(
filename
));
TRACE
(
"
filenam
e (%s)
\n
"
,
debugstr_w
(
filename
));
*
ppObj
=
NULL
;
...
...
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