Changeset 1082 for trunk/dll/cmdline.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/cmdline.c

    r1039 r1082  
    77
    88  Copyright (c) 1993-98 M. Kimes
    9   Copyright (c) 2004, 2007 Steven H.Levine
     9  Copyright (c) 2004, 2008 Steven H.Levine
    1010
    1111  01 Aug 04 SHL Rework lstrip/rstrip usage
     
    1818  29 Feb 08 GKY Use xfree where appropriate
    1919  20 Apr 08 GKY New variable names; Save and Load command lines of user set length
     20  19 Jul 08 GKY Replace save_dir2(dir) with pFM2SaveDirectory and use BldFullPathName
    2021
    2122***********************************************************************/
     
    7475    else
    7576      MiniLoaded = TRUE;
    76     save_dir2(pszCmdLine);
     77    BldFullPathName(pszCmdLine, pFM2SaveDirectory, (DoItYourself) ? "CMDLINES.DAT" : "CMDMINI.DAT");
     78    /*save_dir2(pszCmdLine);
    7779    if (pszCmdLine[strlen(pszCmdLine) - 1] != '\\')
    7880      strcat(pszCmdLine, "\\");
    79     strcat(pszCmdLine, (DoItYourself) ? "CMDLINES.DAT" : "CMDMINI.DAT");
     81    strcat(pszCmdLine, (DoItYourself) ? "CMDLINES.DAT" : "CMDMINI.DAT");*/
    8082    fp = _fsopen(pszCmdLine, "r", SH_DENYWR);
    8183    if (fp) {
     
    130132  if (!pszCmdLine)
    131133    return;
    132   save_dir2(pszCmdLine);
     134  BldFullPathName(pszCmdLine, pFM2SaveDirectory, (DoItYourself) ? "CMDLINES.DAT" : "CMDMINI.DAT");
     135  /*save_dir2(pszCmdLine);
    133136  if (pszCmdLine[strlen(pszCmdLine) - 1] != '\\')
    134137    strcat(pszCmdLine, "\\");
    135   strcat(pszCmdLine, (DoItYourself) ? "CMDLINES.DAT" : "CMDMINI.DAT");
     138  strcat(pszCmdLine, (DoItYourself) ? "CMDLINES.DAT" : "CMDMINI.DAT");*/
    136139  if (CmdLineHead) {
    137140    fp = xfopen(pszCmdLine, "w", pszSrcFile, __LINE__);
Note: See TracChangeset for help on using the changeset viewer.