Changeset 452 for trunk/dll/error.c


Ignore:
Timestamp:
Aug 24, 2006, 7:02:16 AM (19 years ago)
Author:
root
Message:

Tweak message formatting

File:
1 edited

Legend:

Unmodified
Added
Removed
  • trunk/dll/error.c

    r383 r452  
    1919  22 Jul 06 SHL Optimize calling sequences
    2020  26 Jul 06 SHL Add ..._Error2
     21  16 Aug 06 SHL Tweak message formatting
    2122
    2223***********************************************************************/
     
    4041static APIRET showMsg(ULONG mb_type, HWND hwnd, PCSZ pszTitle, PCSZ pszMsg);
    4142
    42 //== Win_Error: report Win...() error ===
     43//== Win_Error: report Win...() error using passed message string ===
    4344
    4445VOID Win_Error(HWND hwndErr, HWND hwndOwner, PCSZ pszFileName, ULONG ulLineNo, PCSZ pszFmt,...)
     
    6465
    6566  if (strchr(szMsg, ' ') == NULL)
    66     strcat(szMsg, " failed");                   // Assume simple function name
     67    strcat(szMsg, " failed.");                  // Assume simple function name
    6768
    6869  // Append file name and line number
     
    7576  if (!pErrInfoBlk) {
    7677    psz = szMsg + strlen(szMsg);
    77     strcpy(psz, " WinGetError failed");
     78    strcpy(psz, " WinGetError failed.");
    7879  }
    7980  else {
     
    103104} // Win_Error
    104105
     106//== Win_Error2: report Win...() error using passed message id ===
     107
    105108VOID Win_Error2(HWND hwndErr, HWND hwndOwner, PCSZ pszFileName, ULONG ulLineNo, UINT idMsg)
    106109{
     
    109112} // Win_Error2
    110113
    111 //== Dos_Error: report Dos...() error ===
     114//== Dos_Error: report Dos...() error using passed message string ===
    112115
    113116INT Dos_Error(ULONG mb_type, ULONG ulRC, HWND hwndOwner, PCSZ pszFileName,
     
    132135
    133136  if (strchr(szMsg, ' ') == NULL)
    134     strcat(szMsg, " failed");                   // Assume simple function name
     137    strcat(szMsg, " failed.");                  // Assume simple function name
    135138
    136139  DosErrClass(ulRC, &Class, &action, &Locus);
     
    185188} // Dos_Error
    186189
    187 //== Dos_Error2: report Dos...() error ===
     190//== Dos_Error2: report Dos...() error using passed message id ===
    188191
    189192INT Dos_Error2(ULONG mb_type, ULONG ulRC, HWND hwndOwner, PCSZ pszFileName,
     
    194197} // Dos_Error2
    195198
    196 //== Runtime_Error: report runtime library error ===
     199//== Runtime_Error: report runtime library error using passed message string ===
    197200
    198201VOID Runtime_Error(PCSZ pszSrcFile, UINT uSrcLineNo, PCSZ pszFmt,...)
     
    208211
    209212  if (strchr(szMsg, ' ') == NULL)
    210     strcat(szMsg, " failed");                   // Assume simple function name
     213    strcat(szMsg, " failed.");                  // Assume simple function name
    211214
    212215  sprintf(szMsg + strlen(szMsg),
     
    220223} // Runtime_Error
    221224
     225//== Runtime_Error2: report runtime library error using passed message id ===
     226
    222227VOID Runtime_Error2(PCSZ pszSrcFile, UINT uSrcLineNo, UINT idMsg)
    223228{
     
    228233// fixme to be rename to Misc_Error
    229234
    230 //=== saymsg: report misc error ===
     235//=== saymsg: report misc error using passed message ===
    231236
    232237APIRET saymsg(ULONG mb_type, HWND hwnd, PCSZ pszTitle, PCSZ pszFmt,...)
     
    239244  va_end(va);
    240245
    241   return showMsg(mb_type,
    242                  hwnd,
    243                  pszTitle,
    244                  szMsg);
     246  return showMsg(mb_type,hwnd,pszTitle,szMsg);
     247
    245248} // saymsg
    246249
    247 //=== showMsg: report misc error ===
     250//=== showMsg: display error popup ===
    248251
    249252static APIRET showMsg(ULONG mb_type, HWND hwnd, PCSZ pszTitle, PCSZ pszMsg)
Note: See TracChangeset for help on using the changeset viewer.