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
3de56aa9
Commit
3de56aa9
authored
Jul 20, 2011
by
Michael Stefaniuc
Committed by
Alexandre Julliard
Jul 20, 2011
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
qmgr: COM cleanup for the IClassFactory iface.
parent
2507d6e5
Hide whitespace changes
Inline
Side-by-side
Showing
3 changed files
with
13 additions
and
17 deletions
+13
-17
factory.c
dlls/qmgr/factory.c
+10
-13
qmgr.h
dlls/qmgr/qmgr.h
+1
-1
service.c
dlls/qmgr/service.c
+2
-3
No files found.
dlls/qmgr/factory.c
View file @
3de56aa9
...
...
@@ -26,20 +26,17 @@
WINE_DEFAULT_DEBUG_CHANNEL
(
qmgr
);
static
ULONG
WINAPI
BITS_IClassFactory_AddRef
(
LPCLASSFACTORY
iface
)
BITS_IClassFactory_AddRef
(
IClassFactory
*
iface
)
{
return
2
;
return
2
;
/* non-heap based object */
}
static
HRESULT
WINAPI
BITS_IClassFactory_QueryInterface
(
LPCLASSFACTORY
iface
,
REFIID
riid
,
LPVOID
*
ppvObj
)
BITS_IClassFactory_QueryInterface
(
IClassFactory
*
iface
,
REFIID
riid
,
void
**
ppvObj
)
{
ClassFactoryImpl
*
This
=
(
ClassFactoryImpl
*
)
iface
;
if
(
IsEqualGUID
(
riid
,
&
IID_IUnknown
)
||
IsEqualGUID
(
riid
,
&
IID_IClassFactory
))
{
*
ppvObj
=
&
This
->
lpVtbl
;
*
ppvObj
=
&
BITS_ClassFactory
.
IClassFactory_iface
;
return
S_OK
;
}
...
...
@@ -48,14 +45,14 @@ BITS_IClassFactory_QueryInterface(LPCLASSFACTORY iface, REFIID riid,
}
static
ULONG
WINAPI
BITS_IClassFactory_Release
(
LPCLASSFACTORY
iface
)
BITS_IClassFactory_Release
(
IClassFactory
*
iface
)
{
return
1
;
return
1
;
/* non-heap based object */
}
static
HRESULT
WINAPI
BITS_IClassFactory_CreateInstance
(
LPCLASSFACTORY
iface
,
LPUNKNOWN
pUnkOuter
,
REFIID
riid
,
LPVOID
*
ppvObj
)
BITS_IClassFactory_CreateInstance
(
IClassFactory
*
iface
,
IUnknown
*
pUnkOuter
,
REFIID
riid
,
void
*
*
ppvObj
)
{
HRESULT
res
;
IUnknown
*
punk
=
NULL
;
...
...
@@ -75,7 +72,7 @@ BITS_IClassFactory_CreateInstance(LPCLASSFACTORY iface, LPUNKNOWN pUnkOuter,
}
static
HRESULT
WINAPI
BITS_IClassFactory_LockServer
(
LPCLASSFACTORY
iface
,
BOOL
fLock
)
BITS_IClassFactory_LockServer
(
IClassFactory
*
iface
,
BOOL
fLock
)
{
FIXME
(
"Not implemented
\n
"
);
return
E_NOTIMPL
;
...
...
@@ -92,5 +89,5 @@ static const IClassFactoryVtbl BITS_IClassFactory_Vtbl =
ClassFactoryImpl
BITS_ClassFactory
=
{
&
BITS_IClassFactory_Vtbl
{
&
BITS_IClassFactory_Vtbl
}
};
dlls/qmgr/qmgr.h
View file @
3de56aa9
...
...
@@ -90,7 +90,7 @@ typedef struct
typedef
struct
{
const
IClassFactoryVtbl
*
lpVtbl
;
IClassFactory
IClassFactory_iface
;
}
ClassFactoryImpl
;
extern
HANDLE
stop_event
DECLSPEC_HIDDEN
;
...
...
dlls/qmgr/service.c
View file @
3de56aa9
...
...
@@ -95,9 +95,8 @@ StartCount(void)
return
FALSE
;
hr
=
CoRegisterClassObject
(
&
CLSID_BackgroundCopyManager
,
(
IUnknown
*
)
&
BITS_ClassFactory
,
CLSCTX_LOCAL_SERVER
,
REGCLS_MULTIPLEUSE
,
&
dwReg
);
(
IUnknown
*
)
&
BITS_ClassFactory
.
IClassFactory_iface
,
CLSCTX_LOCAL_SERVER
,
REGCLS_MULTIPLEUSE
,
&
dwReg
);
if
(
FAILED
(
hr
))
return
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