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
43d5d867
Commit
43d5d867
authored
Aug 22, 2013
by
Nikolay Sivov
Committed by
Alexandre Julliard
Aug 22, 2013
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
ole32: Fix IClassFactory initialization and QueryInterface behavior for GIT.
parent
5f2e48f7
Hide whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
15 additions
and
4 deletions
+15
-4
git.c
dlls/ole32/git.c
+4
-4
marshal.c
dlls/ole32/tests/marshal.c
+11
-0
No files found.
dlls/ole32/git.c
View file @
43d5d867
...
...
@@ -311,8 +311,8 @@ static HRESULT WINAPI
GITCF_QueryInterface
(
LPCLASSFACTORY
iface
,
REFIID
riid
,
LPVOID
*
ppv
)
{
*
ppv
=
NULL
;
if
(
IsEqualIID
(
riid
,
&
IID_IUnknown
)
||
IsEqualIID
(
riid
,
&
IID_IGlobalInterfaceTable
))
if
(
IsEqualIID
(
riid
,
&
IID_IUnknown
)
||
IsEqualIID
(
riid
,
&
IID_IClassFactory
))
{
*
ppv
=
iface
;
return
S_OK
;
...
...
@@ -357,11 +357,11 @@ static const IClassFactoryVtbl GITClassFactoryVtbl = {
GITCF_LockServer
};
static
const
IClassFactoryVtbl
*
PGITClassFactoryVtbl
=
&
GITClassFactoryVtbl
;
static
IClassFactory
git_classfactory
=
{
&
GITClassFactoryVtbl
}
;
HRESULT
StdGlobalInterfaceTable_GetFactory
(
LPVOID
*
ppv
)
{
*
ppv
=
&
PGITClassFactoryVtbl
;
*
ppv
=
&
git_classfactory
;
TRACE
(
"Returning GIT classfactory
\n
"
);
return
S_OK
;
}
...
...
dlls/ole32/tests/marshal.c
View file @
43d5d867
...
...
@@ -40,6 +40,7 @@ DEFINE_GUID(CLSID_ManualResetEvent, 0x0000032c,0x0000,0x0000,0xc0,0x00,0x0
/* functions that are not present on all versions of Windows */
static
HRESULT
(
WINAPI
*
pCoInitializeEx
)(
LPVOID
lpReserved
,
DWORD
dwCoInit
);
static
HRESULT
(
WINAPI
*
pDllGetClassObject
)(
REFCLSID
,
REFIID
,
LPVOID
);
/* helper macros to make tests a bit leaner */
#define ok_more_than_one_lock() ok(cLocks > 0, "Number of locks should be > 0, but actually is %d\n", cLocks)
...
...
@@ -2804,10 +2805,19 @@ static void test_globalinterfacetable(void)
struct
git_params
params
;
DWORD
ret
;
IUnknown
*
object
;
IClassFactory
*
cf
;
trace
(
"test_globalinterfacetable
\n
"
);
cLocks
=
0
;
hr
=
pDllGetClassObject
(
&
CLSID_StdGlobalInterfaceTable
,
&
IID_IClassFactory
,
(
void
**
)
&
cf
);
ok
(
hr
==
S_OK
,
"got 0x%08x
\n
"
,
hr
);
hr
=
IClassFactory_QueryInterface
(
cf
,
&
IID_IGlobalInterfaceTable
,
(
void
**
)
&
object
);
ok
(
hr
==
E_NOINTERFACE
,
"got 0x%08x
\n
"
,
hr
);
IClassFactory_Release
(
cf
);
hr
=
CoCreateInstance
(
&
CLSID_StdGlobalInterfaceTable
,
NULL
,
CLSCTX_INPROC_SERVER
,
&
IID_IGlobalInterfaceTable
,
(
void
**
)
&
git
);
ok_ole_success
(
hr
,
CoCreateInstance
);
...
...
@@ -3149,6 +3159,7 @@ START_TEST(marshal)
}
pCoInitializeEx
=
(
void
*
)
GetProcAddress
(
hOle32
,
"CoInitializeEx"
);
pDllGetClassObject
=
(
void
*
)
GetProcAddress
(
hOle32
,
"DllGetClassObject"
);
argc
=
winetest_get_mainargs
(
&
argv
);
if
(
argc
>
2
&&
(
!
strcmp
(
argv
[
2
],
"-Embedding"
)))
...
...
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