Changeset 1082 for trunk/dll/command.c

Show
Ignore:
Timestamp:
07/20/08 00:37:36 (5 months ago)
Author:
gyoung
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.

Files:
1 modified

Legend:

Unmodified
Added
Removed
  • trunk/dll/command.c

    r1078 r1082  
    2525  29 Feb 08 GKY Use xfree where appropriate 
    2626  18 Jul 08 SHL Add Fortify support 
     27  19 Jul 08 GKY Replace save_dir2(dir) with pFM2SaveDirectory and use BldFullPathName 
    2728 
    2829***********************************************************************/ 
     
    331332  pszCmdLine = xmallocz(MaxComLineStrg, pszSrcFile, __LINE__); 
    332333  if (pszCmdLine) { 
    333     save_dir2(pszCmdLine); 
     334    BldFullPathName(pszCmdLine, pFM2SaveDirectory, "COMMANDS.DAT"); 
     335    /*save_dir2(pszCmdLine); 
    334336    if (pszCmdLine[strlen(pszCmdLine) - 1] != '\\') 
    335337      strcat(pszCmdLine, "\\"); 
    336     strcat(pszCmdLine, "COMMANDS.DAT"); 
     338    strcat(pszCmdLine, "COMMANDS.DAT");*/ 
    337339    fp = _fsopen(pszCmdLine, "r", SH_DENYWR); 
    338340    if (fp) { 
     
    399401    return; 
    400402  info = cmdhead; 
    401   save_dir2(s); 
     403  BldFullPathName(s, pFM2SaveDirectory, "COMMANDS.DAT"); 
     404  /*save_dir2(s); 
    402405  if (s[strlen(s) - 1] != '\\') 
    403406    strcat(s, "\\"); 
    404   strcat(s, "COMMANDS.DAT"); 
     407  strcat(s, "COMMANDS.DAT");*/ 
    405408  fp = xfopen(s, "w", pszSrcFile, __LINE__); 
    406409  if (fp) {