Source code of Windows XP (NT5)
You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.

120 lines
1.7 KiB

  1. /*++
  2. Copyright (c) 1991-1995 Microsoft Corporation
  3. Module Name:
  4. rpc.h
  5. Abstract:
  6. Master include file for RPC applications.
  7. --*/
  8. #ifndef RPC_NO_WINDOWS_H
  9. #include <windows.h>
  10. #endif // RPC_NO_WINDOWS_H
  11. #ifndef __RPC_H__
  12. #define __RPC_H__
  13. #ifdef __cplusplus
  14. extern "C" {
  15. #endif
  16. #define __RPC_WIN32__
  17. #ifndef __MIDL_USER_DEFINED
  18. #define midl_user_allocate MIDL_user_allocate
  19. #define midl_user_free MIDL_user_free
  20. #define __MIDL_USER_DEFINED
  21. #endif
  22. typedef void * I_RPC_HANDLE;
  23. typedef long RPC_STATUS;
  24. #define RPC_UNICODE_SUPPORTED
  25. #if (_MSC_VER >= 800)
  26. #define __RPC_FAR
  27. #define __RPC_API __stdcall
  28. #define __RPC_USER __stdcall
  29. #define __RPC_STUB __stdcall
  30. #define RPC_ENTRY __stdcall
  31. #else
  32. #define __RPC_FAR
  33. #define __RPC_API
  34. #define __RPC_USER
  35. #define __RPC_STUB
  36. #define RPC_ENTRY
  37. #endif
  38. #ifdef IN
  39. #undef IN
  40. #undef OUT
  41. #undef OPTIONAL
  42. #endif /* IN */
  43. #include "rpcdce.h"
  44. #include "rpcnsi.h"
  45. #include "rpcnterr.h"
  46. #include <excpt.h>
  47. #include <winerror.h>
  48. #define RpcTryExcept \
  49. __try \
  50. {
  51. // trystmts
  52. #define RpcExcept(expr) \
  53. } \
  54. __except (expr) \
  55. {
  56. // exceptstmts
  57. #define RpcEndExcept \
  58. }
  59. #define RpcTryFinally \
  60. __try \
  61. {
  62. // trystmts
  63. #define RpcFinally \
  64. } \
  65. __finally \
  66. {
  67. // finallystmts
  68. #define RpcEndFinally \
  69. }
  70. #define RpcExceptionCode() GetExceptionCode()
  71. #define RpcAbnormalTermination() AbnormalTermination()
  72. RPC_STATUS RPC_ENTRY
  73. RpcImpersonateClient (
  74. IN RPC_BINDING_HANDLE BindingHandle OPTIONAL
  75. );
  76. RPC_STATUS RPC_ENTRY
  77. RpcRevertToSelf (
  78. );
  79. long RPC_ENTRY
  80. I_RpcMapWin32Status (
  81. IN RPC_STATUS Status
  82. );
  83. #ifdef __cplusplus
  84. }
  85. #endif
  86. #endif // __RPC_H__