ReactOS Fundraising Campaign 2012
 
€ 4,060 / € 30,000

Information | Donate

Home | Info | Community | Development | myReactOS | Contact Us

  1. Home
  2. Community
  3. Development
  4. myReactOS
  5. Fundraiser 2012

  1. Main Page
  2. Alphabetical List
  3. Data Structures
  4. Directories
  5. File List
  6. Data Fields
  7. Globals
  8. Related Pages

ReactOS Development > Doxygen

CrNtDecl.h
Go to the documentation of this file.
00001 
00002 #ifdef CROSSNT_DECL
00003 #undef CROSSNT_DECL
00004 #undef CROSSNT_DECL_EX
00005 #endif //CROSSNT_DECL
00006 
00007 /***************************/
00008 #ifdef CROSSNT_DECL_API
00009 
00010 #define CROSSNT_DECL(type, dspec, name, args, callargs) \
00011 typedef type (dspec *ptr##name) args;        \
00012 extern "C" ptr##name CrNt##name; \
00013 type dspec CrNt##name##_impl args;
00014 
00015 #define CROSSNT_DECL_EX(mod, type, dspec, name, args, callargs) \
00016 typedef type (dspec *ptr##name) args;        \
00017 extern "C" ptr##name CrNt##name; \
00018 type dspec CrNt##name##_impl args;
00019 
00020 #endif //CROSSNT_DECL_API
00021 
00022 /***************************/
00023 #ifdef CROSSNT_DECL_STUB
00024 
00025 #define CROSSNT_DECL(type, dspec, name, args, callargs) \
00026 extern "C" ptr##name CrNt##name = NULL;          \
00027 
00028 #define CROSSNT_DECL_EX(mod, type, dspec, name, args, callargs) \
00029 extern "C" ptr##name CrNt##name = NULL;          \
00030 
00031 #endif //CROSSNT_DECL_STUB
00032 
00033 /***************************/
00034 #ifdef CROSSNT_INIT_STUB
00035 
00036 #define CROSSNT_DECL(type, dspec, name, args, callargs) \
00037     KdPrint(("Init " #name " cur %x\n", CrNt##name)); \
00038     if(!CrNt##name) {                 \
00039         CrNt##name = (ptr##name)CrNtGetProcAddress(g_hNtosKrnl, #name); \
00040         KdPrint(("  GetProcAddr(NTOSKRNL.EXE," #name ") = %x\n", CrNt##name)); \
00041         if(!CrNt##name) {             \
00042             CrNt##name = CrNt##name##_impl; \
00043         }                              \
00044         KdPrint(("  final %\n", CrNt##name)); \
00045     }
00046 
00047 #define CROSSNT_DECL_EX(mod, type, dspec, name, args, callargs) \
00048     KdPrint(("Init " mod "," #name " cur %x\n", CrNt##name)); \
00049     if(!CrNt##name) {                 \
00050         CrNt##name = (ptr##name)CrNtGetProcAddress(CrNtGetModuleBase(mod), #name); \
00051         KdPrint(("  GetProcAddr(" mod "," #name ") = %x\n", CrNt##name)); \
00052         if(!CrNt##name) {             \
00053             CrNt##name = CrNt##name##_impl; \
00054         }                              \
00055         KdPrint(("  final %x\n", CrNt##name)); \
00056     }
00057 
00058 #endif //CROSSNT_INIT_STUB

Generated on Tue May 22 2012 04:32:20 for ReactOS by doxygen 1.7.6.1

ReactOS is a registered trademark or a trademark of ReactOS Foundation in the United States and other countries.