Changeset 1082 for trunk/dll/tools.c


Ignore:
Timestamp:
Jul 20, 2008, 12:37:36 AM (17 years ago)
Author:
Gregg Young
Message:

Changes so FM2 will use TMP/TEMP directory for all temp files; Replaced save_dir2 with global variable so BldFullPathName could easily replace code that performed the same function; Added #ifdef FORTIFY to free_ function that are only used when fortified.

File:
1 edited

Legend:

Unmodified
Added
Removed
  • trunk/dll/tools.c

    r1079 r1082  
    1818  20 Aug 07 GKY Move #pragma alloc_text to end for OpenWatcom compat
    1919  29 Feb 08 GKY Use xfree where appropriate
     20  19 Jul 08 GKY Replace save_dir2(dir) with pFM2SaveDirectory and use BldFullPathName
    2021
    2122***********************************************************************/
     
    3435#include "errutil.h"                    // Dos_Error...
    3536#include "strutil.h"                    // GetPString
     37#include "pathutil.h"                   // BldFullPathName
    3638#include "fortify.h"
    3739#include "fm3dll.h"
     
    6062    return;
    6163  }
    62   save_dir2(s);
     64  BldFullPathName(s, pFM2SaveDirectory, "QUICKTLS.DAT");
     65  /*save_dir2(s);
    6366  if (s[strlen(s) - 1] != '\\')
    6467    strcat(s, "\\");
    65   strcat(s, "QUICKTLS.DAT");
     68  strcat(s, "QUICKTLS.DAT");*/
    6669  fp = _fsopen(s, "r", SH_DENYWR);
    6770  if (fp) {
     
    9396  if (!quicktool[0])
    9497    return;
    95   save_dir2(s);
     98  BldFullPathName(s, pFM2SaveDirectory, "QUICKTLS.DAT");
     99  /*save_dir2(s);
    96100  if (s[strlen(s) - 1] != '\\')
    97101    strcat(s, "\\");
    98   strcat(s, "QUICKTLS.DAT");
     102  strcat(s, "QUICKTLS.DAT");*/
    99103  fp = xfopen(s, "w", pszSrcFile, __LINE__);
    100104  if (fp) {
Note: See TracChangeset for help on using the changeset viewer.