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
9a4959de
Commit
9a4959de
authored
Jan 24, 2020
by
Nikolay Sivov
Committed by
Alexandre Julliard
Jan 24, 2020
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
ole32: Fix IsEqual() for antimoniker.
Signed-off-by:
Nikolay Sivov
<
nsivov@codeweavers.com
>
Signed-off-by:
Alexandre Julliard
<
julliard@winehq.org
>
parent
b9ce037a
Show whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
17 additions
and
16 deletions
+17
-16
antimoniker.c
dlls/ole32/antimoniker.c
+17
-11
moniker.c
dlls/ole32/tests/moniker.c
+0
-5
No files found.
dlls/ole32/antimoniker.c
View file @
9a4959de
...
...
@@ -53,6 +53,7 @@ static inline AntiMonikerImpl *impl_from_IROTData(IROTData *iface)
return
CONTAINING_RECORD
(
iface
,
AntiMonikerImpl
,
IROTData_iface
);
}
static
AntiMonikerImpl
*
unsafe_impl_from_IMoniker
(
IMoniker
*
iface
);
/*******************************************************************************
* AntiMoniker_QueryInterface
...
...
@@ -308,22 +309,20 @@ AntiMonikerImpl_Enum(IMoniker* iface,BOOL fForward, IEnumMoniker** ppenumMoniker
/******************************************************************************
* AntiMoniker_IsEqual
******************************************************************************/
static
HRESULT
WINAPI
AntiMonikerImpl_IsEqual
(
IMoniker
*
iface
,
IMoniker
*
pmkOtherMoniker
)
static
HRESULT
WINAPI
AntiMonikerImpl_IsEqual
(
IMoniker
*
iface
,
IMoniker
*
other
)
{
DWORD
mkSys
;
TRACE
(
"(%p,%p)
\n
"
,
iface
,
pmkOtherMoniker
);
AntiMonikerImpl
*
moniker
=
impl_from_IMoniker
(
iface
),
*
other_moniker
;
if
(
pmkOtherMoniker
==
NULL
)
return
S_FALSE
;
TRACE
(
"%p, %p.
\n
"
,
iface
,
other
);
IMoniker_IsSystemMoniker
(
pmkOtherMoniker
,
&
mkSys
);
if
(
!
other
)
return
E_INVALIDARG
;
if
(
mkSys
==
MKSYS_ANTIMONIKER
)
return
S_OK
;
else
other_moniker
=
unsafe_impl_from_IMoniker
(
other
);
if
(
!
other_moniker
)
return
S_FALSE
;
return
moniker
->
count
==
other_moniker
->
count
?
S_OK
:
S_FALSE
;
}
/******************************************************************************
...
...
@@ -588,6 +587,13 @@ static const IMonikerVtbl VT_AntiMonikerImpl =
AntiMonikerImpl_IsSystemMoniker
};
static
AntiMonikerImpl
*
unsafe_impl_from_IMoniker
(
IMoniker
*
iface
)
{
if
(
iface
->
lpVtbl
!=
&
VT_AntiMonikerImpl
)
return
NULL
;
return
CONTAINING_RECORD
(
iface
,
AntiMonikerImpl
,
IMoniker_iface
);
}
/********************************************************************************/
/* Virtual function table for the IROTData class. */
static
const
IROTDataVtbl
VT_ROTDataImpl
=
...
...
dlls/ole32/tests/moniker.c
View file @
9a4959de
...
...
@@ -2331,11 +2331,9 @@ todo_wine
ok
(
hr
==
S_OK
,
"Unexpected hr %#x.
\n
"
,
hr
);
hr
=
IMoniker_IsEqual
(
moniker
,
moniker2
);
todo_wine
ok
(
hr
==
S_FALSE
,
"Unexpected hr %#x.
\n
"
,
hr
);
hr
=
IMoniker_IsEqual
(
moniker2
,
moniker
);
todo_wine
ok
(
hr
==
S_FALSE
,
"Unexpected hr %#x.
\n
"
,
hr
);
hr
=
IMoniker_Hash
(
moniker
,
&
hash
);
...
...
@@ -2374,11 +2372,9 @@ todo_wine
ok
(
hr
==
S_OK
,
"Unexpected hr %#x.
\n
"
,
hr
);
hr
=
IMoniker_IsEqual
(
moniker
,
moniker2
);
todo_wine
ok
(
hr
==
S_FALSE
,
"Unexpected hr %#x.
\n
"
,
hr
);
hr
=
IMoniker_IsEqual
(
moniker2
,
moniker
);
todo_wine
ok
(
hr
==
S_FALSE
,
"Unexpected hr %#x.
\n
"
,
hr
);
hr
=
IMoniker_Hash
(
moniker
,
&
hash
);
...
...
@@ -2403,7 +2399,6 @@ todo_wine
ok
(
hr
==
S_OK
,
"Unexpected hr %#x.
\n
"
,
hr
);
hr
=
IMoniker_IsEqual
(
moniker
,
NULL
);
todo_wine
ok
(
hr
==
E_INVALIDARG
,
"Unexpected hr %#x.
\n
"
,
hr
);
IStream_Release
(
stream
);
...
...
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