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
bb7e49a4
Commit
bb7e49a4
authored
Jan 02, 2003
by
Alberto Massari
Committed by
Alexandre Julliard
Jan 02, 2003
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
IBindCtx::RegisterObjectParam is supposed to replace the old value if
the key is already registered.
parent
521aa741
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
14 additions
and
5 deletions
+14
-5
bindctx.c
dlls/ole32/bindctx.c
+14
-5
No files found.
dlls/ole32/bindctx.c
View file @
bb7e49a4
...
...
@@ -371,15 +371,24 @@ HRESULT WINAPI BindCtxImpl_GetRunningObjectTable(IBindCtx* iface,IRunningObjectT
******************************************************************************/
HRESULT
WINAPI
BindCtxImpl_RegisterObjectParam
(
IBindCtx
*
iface
,
LPOLESTR
pszkey
,
IUnknown
*
punk
)
{
DWORD
index
=
0
;
ICOM_THIS
(
BindCtxImpl
,
iface
);
TRACE
(
"(%p,%
p,%p)
\n
"
,
This
,
pszkey
,
punk
);
TRACE
(
"(%p,%
s,%p)
\n
"
,
This
,
debugstr_w
(
pszkey
)
,
punk
);
if
(
punk
==
NULL
)
return
E_INVALIDARG
;
IUnknown_AddRef
(
punk
);
if
(
pszkey
!=
NULL
&&
BindCtxImpl_GetObjectIndex
(
This
,
NULL
,
pszkey
,
&
index
)
==
S_OK
)
{
TRACE
(
"Overwriting existing key
\n
"
);
if
(
This
->
bindCtxTable
[
index
].
pObj
!=
NULL
)
IUnknown_Release
(
This
->
bindCtxTable
[
index
].
pObj
);
This
->
bindCtxTable
[
index
].
pObj
=
punk
;
return
S_OK
;
}
This
->
bindCtxTable
[
This
->
bindCtxTableLastIndex
].
pObj
=
punk
;
This
->
bindCtxTable
[
This
->
bindCtxTableLastIndex
].
regType
=
1
;
...
...
@@ -422,7 +431,7 @@ HRESULT WINAPI BindCtxImpl_GetObjectParam(IBindCtx* iface,LPOLESTR pszkey, IUnkn
DWORD
index
;
ICOM_THIS
(
BindCtxImpl
,
iface
);
TRACE
(
"(%p,%
p,%p)
\n
"
,
This
,
pszkey
,
punk
);
TRACE
(
"(%p,%
s,%p)
\n
"
,
This
,
debugstr_w
(
pszkey
)
,
punk
);
if
(
punk
==
NULL
)
return
E_POINTER
;
...
...
@@ -448,7 +457,7 @@ HRESULT WINAPI BindCtxImpl_RevokeObjectParam(IBindCtx* iface,LPOLESTR ppenum)
ICOM_THIS
(
BindCtxImpl
,
iface
);
TRACE
(
"(%p,%
p)
\n
"
,
This
,
ppenum
);
TRACE
(
"(%p,%
s)
\n
"
,
This
,
debugstr_w
(
ppenum
)
);
if
(
BindCtxImpl_GetObjectIndex
(
This
,
NULL
,
ppenum
,
&
index
)
==
S_FALSE
)
return
E_FAIL
;
...
...
@@ -515,8 +524,8 @@ HRESULT WINAPI BindCtxImpl_GetObjectIndex(BindCtxImpl* This,
if
(
found
)
return
S_OK
;
else
return
S_FALSE
;
TRACE
(
"key not found
\n
"
);
return
S_FALSE
;
}
/******************************************************************************
...
...
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