Changeset 1450 for trunk/dll/errutil.c


Ignore:
Timestamp:
Jul 28, 2009, 12:23:55 AM (16 years ago)
Author:
Gregg Young
Message:

Add a PCSZ srting for error messages; prevent error popup for locked text file on directory scan (scan works as expected anyway); Pass file names on stack which is in low mem for DosGetMessage.

File:
1 edited

Legend:

Unmodified
Added
Removed
  • trunk/dll/errutil.c

    r1449 r1450  
    119119{
    120120  CHAR szMsg[4096];
    121   CHAR *szMsgFile, *szMsgFileH;
     121  CHAR szMsgFile[20], szMsgFileH[20];
    122122  ULONG Class;                          // Error class
    123123  ULONG action;                         // Error action
     
    131131    return MBID_ENTER;                  // Should not have been called
    132132
    133   //Allocate low memory for DosGetMessage (16 bit)
    134   DosAllocMem((PVOID) &szMsgFile, CCHMAXPATH,
    135                PAG_COMMIT | PAG_READ | PAG_WRITE);
    136   DosAllocMem((PVOID) &szMsgFileH, CCHMAXPATH,
    137                PAG_COMMIT | PAG_READ | PAG_WRITE);
    138133  // Format caller's message
    139134  va_start(va, pszFmt);
     
    169164      || !DosGetMessage(NULL, 0L, (PCHAR) pszMsgStart + 1, 1024, ulRC,
    170165                        szMsgFileH, &ulMsgLen)) {
    171     DosFreeMem(szMsgFile);
    172     DosFreeMem(szMsgFileH);
    173166    // Got message
    174167    pszMsgStart[ulMsgLen + 1] = 0;      // Terminate
Note: See TracChangeset for help on using the changeset viewer.