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
4356e494
Commit
4356e494
authored
Feb 02, 2010
by
Alexandre Julliard
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
atl: The object map entries for version 1 don't have the last two fields.
parent
9ce56b27
Hide whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
43 additions
and
11 deletions
+43
-11
atl_main.c
dlls/atl/atl_main.c
+21
-11
atlbase.h
dlls/atl/atlbase.h
+22
-0
No files found.
dlls/atl/atl_main.c
View file @
4356e494
...
@@ -97,6 +97,19 @@ HRESULT WINAPI AtlModuleInit(_ATL_MODULEW* pM, _ATL_OBJMAP_ENTRYW* p, HINSTANCE
...
@@ -97,6 +97,19 @@ HRESULT WINAPI AtlModuleInit(_ATL_MODULEW* pM, _ATL_OBJMAP_ENTRYW* p, HINSTANCE
return
S_OK
;
return
S_OK
;
}
}
static
_ATL_OBJMAP_ENTRYW_V1
*
get_objmap_entry
(
_ATL_MODULEW
*
mod
,
unsigned
int
index
)
{
_ATL_OBJMAP_ENTRYW_V1
*
ret
;
if
(
mod
->
cbSize
==
ATLVer1Size
)
ret
=
(
_ATL_OBJMAP_ENTRYW_V1
*
)
mod
->
m_pObjMap
+
index
;
else
ret
=
(
_ATL_OBJMAP_ENTRYW_V1
*
)(
mod
->
m_pObjMap
+
index
);
if
(
!
ret
->
pclsid
)
ret
=
NULL
;
return
ret
;
}
HRESULT
WINAPI
AtlModuleLoadTypeLib
(
_ATL_MODULEW
*
pM
,
LPCOLESTR
lpszIndex
,
HRESULT
WINAPI
AtlModuleLoadTypeLib
(
_ATL_MODULEW
*
pM
,
LPCOLESTR
lpszIndex
,
BSTR
*
pbstrPath
,
ITypeLib
**
ppTypeLib
)
BSTR
*
pbstrPath
,
ITypeLib
**
ppTypeLib
)
{
{
...
@@ -158,6 +171,7 @@ HRESULT WINAPI AtlModuleAddTermFunc(_ATL_MODULEW *pM, _ATL_TERMFUNC *pFunc, DWOR
...
@@ -158,6 +171,7 @@ HRESULT WINAPI AtlModuleAddTermFunc(_ATL_MODULEW *pM, _ATL_TERMFUNC *pFunc, DWOR
HRESULT
WINAPI
AtlModuleRegisterClassObjects
(
_ATL_MODULEW
*
pM
,
DWORD
dwClsContext
,
HRESULT
WINAPI
AtlModuleRegisterClassObjects
(
_ATL_MODULEW
*
pM
,
DWORD
dwClsContext
,
DWORD
dwFlags
)
DWORD
dwFlags
)
{
{
_ATL_OBJMAP_ENTRYW_V1
*
obj
;
HRESULT
hRes
=
S_OK
;
HRESULT
hRes
=
S_OK
;
int
i
=
0
;
int
i
=
0
;
...
@@ -166,10 +180,9 @@ HRESULT WINAPI AtlModuleRegisterClassObjects(_ATL_MODULEW *pM, DWORD dwClsContex
...
@@ -166,10 +180,9 @@ HRESULT WINAPI AtlModuleRegisterClassObjects(_ATL_MODULEW *pM, DWORD dwClsContex
if
(
pM
==
NULL
)
if
(
pM
==
NULL
)
return
E_INVALIDARG
;
return
E_INVALIDARG
;
while
(
pM
->
m_pObjMap
[
i
].
pclsid
!=
NULL
)
while
((
obj
=
get_objmap_entry
(
pM
,
i
++
))
)
{
{
IUnknown
*
pUnknown
;
IUnknown
*
pUnknown
;
_ATL_OBJMAP_ENTRYW
*
obj
=
&
(
pM
->
m_pObjMap
[
i
]);
HRESULT
rc
;
HRESULT
rc
;
TRACE
(
"Registering object %i
\n
"
,
i
);
TRACE
(
"Registering object %i
\n
"
,
i
);
...
@@ -185,7 +198,6 @@ HRESULT WINAPI AtlModuleRegisterClassObjects(_ATL_MODULEW *pM, DWORD dwClsContex
...
@@ -185,7 +198,6 @@ HRESULT WINAPI AtlModuleRegisterClassObjects(_ATL_MODULEW *pM, DWORD dwClsContex
IUnknown_Release
(
pUnknown
);
IUnknown_Release
(
pUnknown
);
}
}
}
}
i
++
;
}
}
return
hRes
;
return
hRes
;
...
@@ -269,6 +281,7 @@ HRESULT WINAPI AtlInternalQueryInterface(void* this, const _ATL_INTMAP_ENTRY* pE
...
@@ -269,6 +281,7 @@ HRESULT WINAPI AtlInternalQueryInterface(void* this, const _ATL_INTMAP_ENTRY* pE
*/
*/
HRESULT
WINAPI
AtlModuleRegisterServer
(
_ATL_MODULEW
*
pM
,
BOOL
bRegTypeLib
,
const
CLSID
*
clsid
)
HRESULT
WINAPI
AtlModuleRegisterServer
(
_ATL_MODULEW
*
pM
,
BOOL
bRegTypeLib
,
const
CLSID
*
clsid
)
{
{
const
_ATL_OBJMAP_ENTRYW_V1
*
obj
;
int
i
;
int
i
;
HRESULT
hRes
;
HRESULT
hRes
;
...
@@ -277,12 +290,10 @@ HRESULT WINAPI AtlModuleRegisterServer(_ATL_MODULEW* pM, BOOL bRegTypeLib, const
...
@@ -277,12 +290,10 @@ HRESULT WINAPI AtlModuleRegisterServer(_ATL_MODULEW* pM, BOOL bRegTypeLib, const
if
(
pM
==
NULL
)
if
(
pM
==
NULL
)
return
E_INVALIDARG
;
return
E_INVALIDARG
;
for
(
i
=
0
;
pM
->
m_pObjMap
[
i
].
pclsid
!=
NULL
;
i
++
)
/* register CLSIDs */
for
(
i
=
0
;
(
obj
=
get_objmap_entry
(
pM
,
i
))
!=
NULL
;
i
++
)
/* register CLSIDs */
{
{
if
(
!
clsid
||
IsEqualCLSID
(
pM
->
m_pObjMap
[
i
].
pclsid
,
clsid
))
if
(
!
clsid
||
IsEqualCLSID
(
obj
->
pclsid
,
clsid
))
{
{
const
_ATL_OBJMAP_ENTRYW
*
obj
=
&
pM
->
m_pObjMap
[
i
];
TRACE
(
"Registering clsid %s
\n
"
,
debugstr_guid
(
obj
->
pclsid
));
TRACE
(
"Registering clsid %s
\n
"
,
debugstr_guid
(
obj
->
pclsid
));
hRes
=
obj
->
pfnUpdateRegistry
(
TRUE
);
/* register */
hRes
=
obj
->
pfnUpdateRegistry
(
TRUE
);
/* register */
if
(
FAILED
(
hRes
))
if
(
FAILED
(
hRes
))
...
@@ -351,6 +362,7 @@ HRESULT WINAPI AtlUnmarshalPtr(IStream *stm, const IID *iid, IUnknown **ppUnk)
...
@@ -351,6 +362,7 @@ HRESULT WINAPI AtlUnmarshalPtr(IStream *stm, const IID *iid, IUnknown **ppUnk)
HRESULT
WINAPI
AtlModuleGetClassObject
(
_ATL_MODULEW
*
pm
,
REFCLSID
rclsid
,
HRESULT
WINAPI
AtlModuleGetClassObject
(
_ATL_MODULEW
*
pm
,
REFCLSID
rclsid
,
REFIID
riid
,
LPVOID
*
ppv
)
REFIID
riid
,
LPVOID
*
ppv
)
{
{
_ATL_OBJMAP_ENTRYW_V1
*
obj
;
int
i
;
int
i
;
HRESULT
hres
=
CLASS_E_CLASSNOTAVAILABLE
;
HRESULT
hres
=
CLASS_E_CLASSNOTAVAILABLE
;
...
@@ -359,12 +371,10 @@ HRESULT WINAPI AtlModuleGetClassObject(_ATL_MODULEW *pm, REFCLSID rclsid,
...
@@ -359,12 +371,10 @@ HRESULT WINAPI AtlModuleGetClassObject(_ATL_MODULEW *pm, REFCLSID rclsid,
if
(
pm
==
NULL
)
if
(
pm
==
NULL
)
return
E_INVALIDARG
;
return
E_INVALIDARG
;
for
(
i
=
0
;
pm
->
m_pObjMap
[
i
].
pclsid
!=
NULL
;
i
++
)
for
(
i
=
0
;
(
obj
=
get_objmap_entry
(
pm
,
i
))
!=
NULL
;
i
++
)
{
{
if
(
IsEqualCLSID
(
pm
->
m_pObjMap
[
i
].
pclsid
,
rclsid
))
if
(
IsEqualCLSID
(
obj
->
pclsid
,
rclsid
))
{
{
_ATL_OBJMAP_ENTRYW
*
obj
=
&
pm
->
m_pObjMap
[
i
];
TRACE
(
"found object %i
\n
"
,
i
);
TRACE
(
"found object %i
\n
"
,
i
);
if
(
obj
->
pfnGetClassObject
)
if
(
obj
->
pfnGetClassObject
)
{
{
...
...
dlls/atl/atlbase.h
View file @
4356e494
...
@@ -33,6 +33,28 @@ typedef LPCWSTR (WINAPI _ATL_DESCRIPTIONFUNCW)(void);
...
@@ -33,6 +33,28 @@ typedef LPCWSTR (WINAPI _ATL_DESCRIPTIONFUNCW)(void);
typedef
const
struct
_ATL_CATMAP_ENTRY
*
(
_ATL_CATMAPFUNC
)(
void
);
typedef
const
struct
_ATL_CATMAP_ENTRY
*
(
_ATL_CATMAPFUNC
)(
void
);
typedef
void
(
WINAPI
_ATL_TERMFUNC
)(
DWORD
dw
);
typedef
void
(
WINAPI
_ATL_TERMFUNC
)(
DWORD
dw
);
typedef
struct
_ATL_OBJMAP_ENTRYA_V1_TAG
{
const
CLSID
*
pclsid
;
HRESULT
(
WINAPI
*
pfnUpdateRegistry
)(
BOOL
bRegister
);
_ATL_CREATORFUNC
*
pfnGetClassObject
;
_ATL_CREATORFUNC
*
pfnCreateInstance
;
IUnknown
*
pCF
;
DWORD
dwRegister
;
_ATL_DESCRIPTIONFUNCA
*
pfnGetObjectDescription
;
}
_ATL_OBJMAP_ENTRYA_V1
;
typedef
struct
_ATL_OBJMAP_ENTRYW_V1_TAG
{
const
CLSID
*
pclsid
;
HRESULT
(
WINAPI
*
pfnUpdateRegistry
)(
BOOL
bRegister
);
_ATL_CREATORFUNC
*
pfnGetClassObject
;
_ATL_CREATORFUNC
*
pfnCreateInstance
;
IUnknown
*
pCF
;
DWORD
dwRegister
;
_ATL_DESCRIPTIONFUNCW
*
pfnGetObjectDescription
;
}
_ATL_OBJMAP_ENTRYW_V1
;
typedef
struct
_ATL_OBJMAP_ENTRYA_TAG
typedef
struct
_ATL_OBJMAP_ENTRYA_TAG
{
{
const
CLSID
*
pclsid
;
const
CLSID
*
pclsid
;
...
...
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