Leaked source code of windows server 2003
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.

57 lines
976 B

  1. //*************************************************************
  2. //
  3. // Copyright (c) Microsoft Corporation 1998
  4. // All rights reserved
  5. //
  6. // debug.hxx
  7. //
  8. //*************************************************************
  9. #ifndef __DEBUG_HXX__
  10. #define __DEBUG_HXX__
  11. extern HANDLE ghUserPolicyEvent;
  12. extern HANDLE ghMachinePolicyEvent;
  13. inline void
  14. ConditionalBreakIntoDebugger()
  15. {
  16. if ( gDebugBreak )
  17. DebugBreak();
  18. }
  19. void
  20. CreatePolicyEvents();
  21. inline void
  22. SignalPolicyStart( BOOL bUser )
  23. {
  24. if ( ! (gDebugLevel & DL_EVENT) )
  25. return;
  26. if ( bUser )
  27. ResetEvent( ghUserPolicyEvent );
  28. else
  29. ResetEvent( ghMachinePolicyEvent );
  30. }
  31. inline void
  32. SignalPolicyEnd( BOOL bUser )
  33. {
  34. if ( ! (gDebugLevel & DL_EVENT) )
  35. return;
  36. if ( bUser )
  37. SetEvent( ghUserPolicyEvent );
  38. else
  39. SetEvent( ghMachinePolicyEvent );
  40. }
  41. #endif // ifndef __DEBUG_HXX__