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.

88 lines
2.0 KiB

  1. //==========================================================================;
  2. //
  3. // THIS CODE AND INFORMATION IS PROVIDED "AS IS" WITHOUT WARRANTY OF ANY
  4. // KIND, EITHER EXPRESSED OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE
  5. // IMPLIED WARRANTIES OF MERCHANTABILITY AND/OR FITNESS FOR A PARTICULAR
  6. // PURPOSE.
  7. //
  8. // Copyright (c) 1992-1994 Microsoft Corporation
  9. //
  10. //--------------------------------------------------------------------------;
  11. //
  12. // debug.h
  13. //
  14. // Description:
  15. //
  16. //
  17. //
  18. //==========================================================================;
  19. #ifndef _INC_DEBUG
  20. #define _INC_DEBUG
  21. #ifdef __cplusplus
  22. extern "C"
  23. {
  24. #endif
  25. //
  26. //
  27. //
  28. //
  29. #ifdef DEBUG
  30. #define DEBUG_SECTION "Debug" // section name for
  31. #define DEBUG_MODULE_NAME "MSACMMAP" // key name and prefix for output
  32. #define DEBUG_MAX_LINE_LEN 255 // max line length (bytes!)
  33. #endif
  34. //
  35. // based code makes since only in win 16 (to try and keep stuff out of
  36. // [fixed] data segments, etc)...
  37. //
  38. #ifndef BCODE
  39. #ifdef WIN32
  40. #define BCODE
  41. #else
  42. #define BCODE _based(_segname("_CODE"))
  43. #endif
  44. #endif
  45. //- - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - ;
  46. //
  47. //
  48. //
  49. //- - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - ;
  50. #ifdef DEBUG
  51. BOOL WINAPI DbgEnable(BOOL fEnable);
  52. UINT WINAPI DbgGetLevel(void);
  53. UINT WINAPI DbgSetLevel(UINT uLevel);
  54. UINT WINAPI DbgInitialize(BOOL fEnable);
  55. void FAR CDECL dprintf(UINT uDbgLevel, LPSTR szFmt, ...);
  56. #define D(x) {x;}
  57. #define DPF dprintf
  58. #define DPI(sz) {static char BCODE ach[] = sz; OutputDebugStr(ach);}
  59. #else
  60. #define DbgEnable(x) FALSE
  61. #define DbgGetLevel() 0
  62. #define DbgSetLevel(x) 0
  63. #define DbgInitialize(x) 0
  64. #ifdef _MSC_VER
  65. #pragma warning(disable:4002)
  66. #endif
  67. #define D(x)
  68. #define DPF()
  69. #define DPI(sz)
  70. #endif
  71. #ifdef __cplusplus
  72. }
  73. #endif
  74. #endif // _INC_DEBUG