Module: wine Branch: master Commit: c9dcef156e6e06e7d2011ca4d8c35754f912acb5 URL: http://source.winehq.org/git/wine.git/?a=commit;h=c9dcef156e6e06e7d2011ca4d8...
Author: Amine Khaldi amine.khaldi@reactos.org Date: Tue Oct 26 18:06:01 2010 +0100
widl: Do not define MIDL_user_allocate and MIDL_user_free as it's already in the psdk.
---
include/rpcndr.h | 3 +++ tools/widl/header.c | 8 -------- 2 files changed, 3 insertions(+), 8 deletions(-)
diff --git a/include/rpcndr.h b/include/rpcndr.h index 8c1b4df..159f802 100644 --- a/include/rpcndr.h +++ b/include/rpcndr.h @@ -111,6 +111,9 @@ typedef unsigned char boolean; #define midl_user_free MIDL_user_free #define midl_user_allocate MIDL_user_allocate
+void * __RPC_USER MIDL_user_allocate(SIZE_T); +void __RPC_USER MIDL_user_free(void *); + #define NdrFcShort(s) (unsigned char)(s & 0xff), (unsigned char)(s >> 8) #define NdrFcLong(s) (unsigned char)(s & 0xff), (unsigned char)((s & 0x0000ff00) >> 8), \ (unsigned char)((s & 0x00ff0000) >> 16), (unsigned char)(s >> 24) diff --git a/tools/widl/header.c b/tools/widl/header.c index eaef867..e0322c6 100644 --- a/tools/widl/header.c +++ b/tools/widl/header.c @@ -1081,14 +1081,6 @@ static void write_rpc_interface_start(FILE *header, const type_t *iface) { unsigned int ver = get_attrv(iface->attrs, ATTR_VERSION); const char *var = get_attrp(iface->attrs, ATTR_IMPLICIT_HANDLE); - static int allocate_written = 0; - - if (!allocate_written) - { - allocate_written = 1; - fprintf(header, "void * __RPC_USER MIDL_user_allocate(SIZE_T);\n"); - fprintf(header, "void __RPC_USER MIDL_user_free(void *);\n\n"); - }
fprintf(header, "/*****************************************************************************\n"); fprintf(header, " * %s interface (v%d.%d)\n", iface->name, MAJORVERSION(ver), MINORVERSION(ver));