[PATCH 5/6] Move common define to a header
Nikolay Sivov
nsivov at codeweavers.com
Sun Dec 26 16:35:37 CST 2010
---
dlls/oleaut32/typelib.c | 2 +-
dlls/oleaut32/typelib.h | 5 ++++-
dlls/oleaut32/typelib2.c | 2 +-
3 files changed, 6 insertions(+), 3 deletions(-)
diff --git a/dlls/oleaut32/typelib.c b/dlls/oleaut32/typelib.c
index 0ea185c..36328a6 100644
--- a/dlls/oleaut32/typelib.c
+++ b/dlls/oleaut32/typelib.c
@@ -2744,7 +2744,7 @@ static HRESULT TLB_Mapping_Open(LPCWSTR path, LPVOID *ppBase, DWORD *pdwTLBLengt
* find the type of the typelib file and map the typelib resource into
* the memory
*/
-#define MSFT_SIGNATURE 0x5446534D /* "MSFT" */
+
#define SLTG_SIGNATURE 0x47544c53 /* "SLTG" */
static HRESULT TLB_ReadTypeLib(LPCWSTR pszFileName, LPWSTR pszPath, UINT cchPath, ITypeLib2 **ppTypeLib)
{
diff --git a/dlls/oleaut32/typelib.h b/dlls/oleaut32/typelib.h
index 058c6a2..3b5f09b 100644
--- a/dlls/oleaut32/typelib.h
+++ b/dlls/oleaut32/typelib.h
@@ -52,8 +52,11 @@
* it is at the beginning of a type lib file
*
*/
+
+#define MSFT_SIGNATURE 0x5446534D /* "MSFT" */
+
typedef struct tagMSFT_Header {
-/*0x00*/INT magic1; /* 0x5446534D "MSFT" */
+/*0x00*/INT magic1; /* 0x5446534D "MSFT" */
INT magic2; /* 0x00010002 version nr? */
INT posguid; /* position of libid in guid table */
/* (should be, else -1) */
diff --git a/dlls/oleaut32/typelib2.c b/dlls/oleaut32/typelib2.c
index 8b59bf4..ce79254 100644
--- a/dlls/oleaut32/typelib2.c
+++ b/dlls/oleaut32/typelib2.c
@@ -260,7 +260,7 @@ static inline SYSKIND ctl2_get_syskind(const ICreateTypeLib2Impl *This)
static void ctl2_init_header(
ICreateTypeLib2Impl *This) /* [I] The typelib to initialize. */
{
- This->typelib_header.magic1 = 0x5446534d;
+ This->typelib_header.magic1 = MSFT_SIGNATURE;
This->typelib_header.magic2 = 0x00010002;
This->typelib_header.posguid = -1;
This->typelib_header.lcid = This->typelib_header.lcid2 = GetUserDefaultLCID();
--
1.5.6.5
--------------000308040004030707030400--
More information about the wine-patches
mailing list