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.

21 lines
551 B

  1. #include "TsunamiP.Hxx"
  2. #pragma hdrstop
  3. #include "DbgMacro.Hxx"
  4. #ifdef DBG
  5. VOID _AssertionFailed( PSTR pszExpression, PSTR pszFilename, ULONG LineNo )
  6. {
  7. CHAR Message[ 1024 ];
  8. pszFilename = strrchr( pszFilename, '\\' ) + 1;
  9. sprintf( Message, "ASSERT(%s) failed.\n\nOccurred at %s line %d\n\nPress Ok to continue, Cancel to debug.", pszExpression, pszFilename, LineNo );
  10. if ( MessageBox( NULL, Message, "Assertion Failed:", MB_OKCANCEL | MB_ICONSTOP | MB_SETFOREGROUND ) != IDOK )
  11. {
  12. DebugBreak();
  13. }
  14. }
  15. #endif //DBG
  16.