include: Make "long" numeric constants LP64/LLP64 proof (mapi*.h)

Michael Stefaniuc mstefani at redhat.de
Mon Nov 21 17:53:28 CST 2011


---
Yes, SUCCESS_SUCCESS is inconsistently defined.



 include/mapi.h     |    2 +-
 include/mapicode.h |    2 +-
 include/mapidefs.h |   36 ++++++++++++++++++------------------
 3 files changed, 20 insertions(+), 20 deletions(-)

diff --git a/include/mapi.h b/include/mapi.h
index 7d19734..548e130 100644
--- a/include/mapi.h
+++ b/include/mapi.h
@@ -84,7 +84,7 @@ typedef struct
 /* Error codes */
 
 #ifndef SUCCESS_SUCCESS
-#define SUCCESS_SUCCESS                 0L
+#define SUCCESS_SUCCESS                 0
 #endif
 
 #define MAPI_USER_ABORT                 1
diff --git a/include/mapicode.h b/include/mapicode.h
index 31e6830..b5bf686 100644
--- a/include/mapicode.h
+++ b/include/mapicode.h
@@ -30,7 +30,7 @@
 #define MAKE_MAPI_S(e) (MAKE_MAPI_SCODE(0,FACILITY_ITF,(e)))
 
 #ifndef SUCCESS_SUCCESS
-#define SUCCESS_SUCCESS     0L
+#define SUCCESS_SUCCESS     __MSABI_LONG(0)
 #endif
 
 /* Errors */
diff --git a/include/mapidefs.h b/include/mapidefs.h
index f06c61f..cd6d8b0 100644
--- a/include/mapidefs.h
+++ b/include/mapidefs.h
@@ -446,12 +446,12 @@ typedef struct _SPropProblemArray
 } SPropProblemArray, *LPSPropProblemArray;
 
 /* FPropContainsProp flags */
-#define FL_FULLSTRING     0x00000ul /* Exact string match */
-#define FL_SUBSTRING      0x00001ul /* Substring match */
-#define FL_PREFIX         0x00002ul /* Prefix match */
-#define FL_IGNORECASE     0x10000ul /* Case insensitive */
-#define FL_IGNORENONSPACE 0x20000ul /* Ignore non spacing characters */
-#define FL_LOOSE          0x40000ul /* Try very hard to match */
+#define FL_FULLSTRING     ((ULONG)0x00000) /* Exact string match */
+#define FL_SUBSTRING      ((ULONG)0x00001) /* Substring match */
+#define FL_PREFIX         ((ULONG)0x00002) /* Prefix match */
+#define FL_IGNORECASE     ((ULONG)0x10000) /* Case insensitive */
+#define FL_IGNORENONSPACE ((ULONG)0x20000) /* Ignore non spacing characters */
+#define FL_LOOSE          ((ULONG)0x40000) /* Try very hard to match */
 
 
 /* Table types returned by IMAPITable_GetStatus() */
@@ -649,18 +649,18 @@ typedef struct _MAPINAMEID
 } MAPINAMEID, *LPMAPINAMEID;
 
 /* Desired notification types (bitflags) */
-#define fnevCriticalError        0x00000001UL
-#define fnevNewMail              0x00000002UL
-#define fnevObjectCreated        0x00000004UL
-#define fnevObjectDeleted        0x00000008UL
-#define fnevObjectModified       0x00000010UL
-#define fnevObjectMoved          0x00000020UL
-#define fnevObjectCopied         0x00000040UL
-#define fnevSearchComplete       0x00000080UL
-#define fnevTableModified        0x00000100UL
-#define fnevStatusObjectModified 0x00000200UL
-#define fnevReservedForMapi      0x40000000UL
-#define fnevExtended             0x80000000UL
+#define fnevCriticalError        ((ULONG)0x00000001)
+#define fnevNewMail              ((ULONG)0x00000002)
+#define fnevObjectCreated        ((ULONG)0x00000004)
+#define fnevObjectDeleted        ((ULONG)0x00000008)
+#define fnevObjectModified       ((ULONG)0x00000010)
+#define fnevObjectMoved          ((ULONG)0x00000020)
+#define fnevObjectCopied         ((ULONG)0x00000040)
+#define fnevSearchComplete       ((ULONG)0x00000080)
+#define fnevTableModified        ((ULONG)0x00000100)
+#define fnevStatusObjectModified ((ULONG)0x00000200)
+#define fnevReservedForMapi      ((ULONG)0x40000000)
+#define fnevExtended             ((ULONG)0x80000000)
 
 /* Type of notification event */
 #define TABLE_CHANGED       1U
-- 
1.7.6.4



More information about the wine-patches mailing list