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
05230781
Commit
05230781
authored
May 22, 2007
by
Rob Shearman
Committed by
Alexandre Julliard
May 23, 2007
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
ole32: Add more tests for global interface table functions.
parent
eebf8df6
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
27 additions
and
1 deletion
+27
-1
marshal.c
dlls/ole32/tests/marshal.c
+27
-1
No files found.
dlls/ole32/tests/marshal.c
View file @
05230781
...
@@ -2588,10 +2588,11 @@ static DWORD CALLBACK get_global_interface_proc(LPVOID pv)
...
@@ -2588,10 +2588,11 @@ static DWORD CALLBACK get_global_interface_proc(LPVOID pv)
hr
);
hr
);
CoInitialize
(
NULL
);
CoInitialize
(
NULL
);
hr
=
IGlobalInterfaceTable_GetInterfaceFromGlobal
(
params
->
git
,
params
->
cookie
,
&
IID_IClassFactory
,
(
void
**
)
&
cf
);
hr
=
IGlobalInterfaceTable_GetInterfaceFromGlobal
(
params
->
git
,
params
->
cookie
,
&
IID_IClassFactory
,
(
void
**
)
&
cf
);
ok_ole_success
(
hr
,
IGlobalInterfaceTable_GetInterfaceFromGlobal
);
ok_ole_success
(
hr
,
IGlobalInterfaceTable_GetInterfaceFromGlobal
);
I
GlobalInterfaceTable_Release
(
params
->
git
);
I
ClassFactory_Release
(
cf
);
CoUninitialize
();
CoUninitialize
();
...
@@ -2607,6 +2608,10 @@ static void test_globalinterfacetable(void)
...
@@ -2607,6 +2608,10 @@ static void test_globalinterfacetable(void)
DWORD
tid
;
DWORD
tid
;
struct
git_params
params
;
struct
git_params
params
;
DWORD
ret
;
DWORD
ret
;
IUnknown
*
object
;
trace
(
"test_globalinterfacetable
\n
"
);
cLocks
=
0
;
hr
=
CoCreateInstance
(
&
CLSID_StdGlobalInterfaceTable
,
NULL
,
CLSCTX_INPROC_SERVER
,
&
IID_IGlobalInterfaceTable
,
(
void
**
)
&
git
);
hr
=
CoCreateInstance
(
&
CLSID_StdGlobalInterfaceTable
,
NULL
,
CLSCTX_INPROC_SERVER
,
&
IID_IGlobalInterfaceTable
,
(
void
**
)
&
git
);
ok_ole_success
(
hr
,
CoCreateInstance
);
ok_ole_success
(
hr
,
CoCreateInstance
);
...
@@ -2614,6 +2619,8 @@ static void test_globalinterfacetable(void)
...
@@ -2614,6 +2619,8 @@ static void test_globalinterfacetable(void)
hr
=
IGlobalInterfaceTable_RegisterInterfaceInGlobal
(
git
,
(
IUnknown
*
)
&
Test_ClassFactory
,
&
IID_IClassFactory
,
&
cookie
);
hr
=
IGlobalInterfaceTable_RegisterInterfaceInGlobal
(
git
,
(
IUnknown
*
)
&
Test_ClassFactory
,
&
IID_IClassFactory
,
&
cookie
);
ok_ole_success
(
hr
,
IGlobalInterfaceTable_RegisterInterfaceInGlobal
);
ok_ole_success
(
hr
,
IGlobalInterfaceTable_RegisterInterfaceInGlobal
);
ok_more_than_one_lock
();
params
.
cookie
=
cookie
;
params
.
cookie
=
cookie
;
params
.
git
=
git
;
params
.
git
=
git
;
/* note: params is on stack so we MUST wait for get_global_interface_proc
/* note: params is on stack so we MUST wait for get_global_interface_proc
...
@@ -2630,6 +2637,25 @@ static void test_globalinterfacetable(void)
...
@@ -2630,6 +2637,25 @@ static void test_globalinterfacetable(void)
}
}
CloseHandle
(
thread
);
CloseHandle
(
thread
);
/* test getting interface from global with different iid */
hr
=
IGlobalInterfaceTable_GetInterfaceFromGlobal
(
git
,
cookie
,
&
IID_IUnknown
,
(
void
**
)
&
object
);
todo_wine
ok_ole_success
(
hr
,
IGlobalInterfaceTable_GetInterfaceFromGlobal
);
if
(
SUCCEEDED
(
hr
))
IUnknown_Release
(
object
);
/* test getting interface from global with same iid */
hr
=
IGlobalInterfaceTable_GetInterfaceFromGlobal
(
git
,
cookie
,
&
IID_IClassFactory
,
(
void
**
)
&
object
);
ok_ole_success
(
hr
,
IGlobalInterfaceTable_GetInterfaceFromGlobal
);
IUnknown_Release
(
object
);
hr
=
IGlobalInterfaceTable_RevokeInterfaceFromGlobal
(
git
,
cookie
);
ok_ole_success
(
hr
,
IGlobalInterfaceTable_RevokeInterfaceFromGlobal
);
todo_wine
ok_no_locks
();
IGlobalInterfaceTable_Release
(
git
);
}
}
static
const
char
*
debugstr_iid
(
REFIID
riid
)
static
const
char
*
debugstr_iid
(
REFIID
riid
)
...
...
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