Go to the source code of this file.
|
int | _matherr (struct _exception *e) |
|
void | WrNotify (const char *CaptionCStr, const char *NotifyCStr) |
|
void | SaveToErrLog (const char *MsgCStr) |
|
void | ExeStop (const char *MsgCStr, const char *ReasonCStr, const char *CondCStr, const char *FNm, const int &LnN) |
|
int _matherr |
( |
struct _exception * |
e | ) |
|
void ExeStop |
( |
const char * |
MsgCStr, |
|
|
const char * |
ReasonCStr, |
|
|
const char * |
CondCStr, |
|
|
const char * |
FNm, |
|
|
const int & |
LnN |
|
) |
| |
Definition at line 88 of file bd.cpp.
91 char ReasonMsgCStr[1000];
99 if (ReasonCStr==NULL){ReasonMsgCStr[0]=0;}
100 else {sprintf(ReasonMsgCStr,
" [Reason:'%s']", ReasonCStr);}
102 char FullMsgCStr[1000];
105 sprintf(FullMsgCStr,
"Execution stopped%s!", ReasonMsgCStr);
107 sprintf(FullMsgCStr,
"Execution stopped: %s%s, file %s, line %d",
108 CondCStr, ReasonMsgCStr, FNm, LnN);
112 sprintf(FullMsgCStr,
"%s\nExecution stopped!", MsgCStr);
114 sprintf(FullMsgCStr,
"Message: %s%s\nExecution stopped: %s, file %s, line %d",
115 MsgCStr, ReasonMsgCStr, CondCStr, FNm, LnN);
121 #if defined(SW_NOABORT)
void ErrNotify(const char *NotifyCStr)
static void Throw(const TStr &MsgStr)
void SaveToErrLog(const char *MsgCStr)
static bool IsOnExeStopF()
static TOnExeStopF GetOnExeStopF()
void SaveToErrLog |
( |
const char * |
MsgCStr | ) |
|
Definition at line 49 of file bd.cpp.
51 char* FNm=
new char[MxFNmLen];
if (FNm==NULL){
return;}
52 int FNmLen=GetModuleFileName(NULL, FNm, MxFNmLen);
if (FNmLen==0){
return;}
53 FNm[FNmLen++]=
'.'; FNm[FNmLen++]=
'E'; FNm[FNmLen++]=
'r'; FNm[FNmLen++]=
'r';
54 FNm[FNmLen++]=char(0);
55 time_t Time=time(NULL);
56 FILE* fOut=fopen(FNm,
"a+b");
if (fOut==NULL){
return;}
57 fprintf(fOut,
"--------\r\n%s\r\n%s%s\r\n--------\r\n",
58 FNm, ctime(&Time), MsgCStr);
void WrNotify |
( |
const char * |
CaptionCStr, |
|
|
const char * |
NotifyCStr |
|
) |
| |
Definition at line 41 of file bd.cpp.
42 #if defined(__CONSOLE__) || defined(_CONSOLE)
43 printf(
"*** %s: %s\n", CaptionCStr, NotifyCStr);
45 MessageBox(NULL, NotifyCStr, CaptionCStr, MB_OK);