[PATCH] Fix windows calltype macros


Ian Bell <IBell@...>
 

From fe6fd9110b7adf964f14b723ddcd0359f765a51c Mon Sep 17 00:00:00 2001

Message-Id: <fe6fd9110b7adf964f14b723ddcd0359f765a51c.1351009380.git.ibell@...>

From: Ian Bell <ibell@...>

Date: Tue, 23 Oct 2012 14:09:37 +0100

Subject: [PATCH] Fix windows calltype macros

 

Entitlements code was using incorrect calltype macros

 

Signed-off-by: Ian Bell <ibell@...>

---

mama/c_cpp/src/c/mama.c        |   12 ++++++------

mama/c_cpp/src/cpp/mamacpp.cpp |    6 +++---

2 files changed, 9 insertions(+), 9 deletions(-)

 

diff --git a/mama/c_cpp/src/c/mama.c b/mama/c_cpp/src/c/mama.c

index c3799fd..98138c7 100644

--- a/mama/c_cpp/src/c/mama.c

+++ b/mama/c_cpp/src/c/mama.c

@@ -64,14 +64,14 @@ extern void initReservedFields (void);

 #if (OEA_MAJVERSION == 2 && OEA_MINVERSION >= 11) || OEA_MAJVERSION > 2

-void WIN32_CB_FUNC_TYPE entitlementDisconnectCallback (oeaClient*,

+void MAMACALLTYPE entitlementDisconnectCallback (oeaClient*,

                                     const OEA_DISCONNECT_REASON,

                                     const char * const,

                                     const char * const,

                                     const char * const);

-void WIN32_CB_FUNC_TYPE entitlementUpdatedCallback (oeaClient*,

+void MAMACALLTYPE entitlementUpdatedCallback (oeaClient*,

                                  int openSubscriptionForbidden);

-void WIN32_CB_FUNC_TYPE entitlementCheckingSwitchCallback (oeaClient*,

+void MAMACALLTYPE entitlementCheckingSwitchCallback (oeaClient*,

                                         int isEntitlementsCheckingDisabled);

#else

@@ -1555,7 +1555,7 @@ mama_registerEntitlementCallbacks (const mamaEntitlementCallbacks* entitlementCa

}

 #if (OEA_MAJVERSION == 2 && OEA_MINVERSION >= 11) || OEA_MAJVERSION > 2

-void WIN32_CB_FUNC_TYPE entitlementDisconnectCallback (oeaClient*                  client,

+void MAMACALLTYPE entitlementDisconnectCallback (oeaClient*                  client,

                                     const OEA_DISCONNECT_REASON reason,

                                     const char * const          userId,

                                     const char * const          host,

@@ -1567,7 +1567,7 @@ void WIN32_CB_FUNC_TYPE entitlementDisconnectCallback (oeaClient*

     }

}

-void WIN32_CB_FUNC_TYPE entitlementUpdatedCallback (oeaClient* client,

+void MAMACALLTYPE entitlementUpdatedCallback (oeaClient* client,

                                  int openSubscriptionForbidden)

{

     if (gEntitlementCallbacks.onEntitlementUpdate != NULL)

@@ -1576,7 +1576,7 @@ void WIN32_CB_FUNC_TYPE entitlementUpdatedCallback (oeaClient* client,

     }

}

-void WIN32_CB_FUNC_TYPE entitlementCheckingSwitchCallback (oeaClient* client,

+void MAMACALLTYPE entitlementCheckingSwitchCallback (oeaClient* client,

                                         int isEntitlementsCheckingDisabled)

{

     if (gEntitlementCallbacks.onEntitlementCheckingSwitch != NULL)

diff --git a/mama/c_cpp/src/cpp/mamacpp.cpp b/mama/c_cpp/src/cpp/mamacpp.cpp

index 6042e22..c570ba3 100644

--- a/mama/c_cpp/src/cpp/mamacpp.cpp

+++ b/mama/c_cpp/src/cpp/mamacpp.cpp

@@ -80,7 +80,7 @@ namespace Wombat

     extern "C"

     {

-        void entitlementDisconnectCB (const sessionDisconnectReason reason,

+        void MAMACALLTYPE entitlementDisconnectCB (const sessionDisconnectReason reason,

                                       const char* userId,

                                       const char* host,

                                       const char* appName)

@@ -94,7 +94,7 @@ namespace Wombat

             }

         }

-        void entitlementUpdateCB ()

+        void MAMACALLTYPE entitlementUpdateCB ()

         {

             if (gMamaEntitlementCallback != NULL)

             {

@@ -102,7 +102,7 @@ namespace Wombat

             }

         }

-        void entitlementCheckingSwitchCB (const int isEntitlementCheckingDisabled)

+        void MAMACALLTYPE entitlementCheckingSwitchCB (const int isEntitlementCheckingDisabled)

         {

             if (gMamaEntitlementCallback != NULL)

             {

--

1.7.9.5

 




Please consider the environment before printing this e-mail.

This e-mail may contain confidential and/or privileged information. If you are not the intended recipient or have received this e-mail in error, please advise the sender immediately by reply e-mail and delete this message and any attachments without retaining a copy.

Any unauthorised copying, disclosure or distribution of the material in this e-mail is strictly forbidden.