Changeset 1120
Legend:
- Unmodified
- Added
- Removed
-
trunk/dll/arccnrs.c
r1117 r1120 57 57 16 Jul 08 GKY Use TMP directory for temp files if present. Use MakeTempName 58 58 19 Jul 08 GKY Replace save_dir2(dir) with pFM2SaveDirectory 59 25 Aug 08 GKY Check TMP directory space warn if lee than 5 MiB prevent archiver from opening if 60 less than 10 KiB (It hangs and can't be closed) 59 61 60 62 ***********************************************************************/ … … 444 446 info = find_type(arcname, NULL); 445 447 arctemp = xmallocz(CCHMAXPATH, pszSrcFile, __LINE__); 448 if (CheckDriveSpaceAvail(ArcTempRoot, ullDATFileSpaceNeeded, ullTmpSpaceNeeded) == 1) 449 saymsg(MB_OK, 450 HWND_DESKTOP, 451 NullStr, 452 GetPString(IDS_ARCTMPDRIVESPACELIMITED), 453 ArcTempRoot); 446 454 MakeTempName(arctemp, ArcTempRoot, 2); 455 447 456 448 457 ReTry: … … 2135 2144 CM_SEARCHSTRING, 2136 2145 MPFROMP(&srch), MPFROMLONG(CMA_FIRST)); 2137 if (pci && (INT) pci != -1) { 2138 2139 USHORT attrib = CRA_CURSORED; 2146 if (pci && (INT) pci != -1) { 2147 2148 USHORT attrib = CRA_CURSORED; 2149 2140 2150 2141 2151 /* make found item current item */ … … 2281 2291 CM_QUERYRECORDEMPHASIS, 2282 2292 MPFROMLONG(CMA_FIRST), MPFROMSHORT(CRA_CURSORED)); 2283 2293 if (pci && (INT) pci != -1) { 2284 2294 if (fSplitStatus && hwndStatus2) { 2285 2295 if (dcd->ullTotalBytes) … … 2635 2645 OpenDirCnr((HWND) 0, hwndMain, dcd->hwndFrame, FALSE, (char *)mp1); 2636 2646 } 2637 else if (mp1 && IsFile(mp1) == 1) { 2647 else if (mp1 && IsFile(mp1) == 1 && 2648 CheckDriveSpaceAvail(ArcTempRoot, ullDATFileSpaceNeeded, ullTmpSpaceNeeded) != 2) { 2638 2649 StartArcCnr(HWND_DESKTOP, 2639 2650 dcd->hwndFrame, (CHAR *) mp1, 4, (ARC_TYPE *) mp2); … … 3365 3376 ArcMenu = ArcCnrMenu = (HWND) 0; 3366 3377 EmptyArcCnr(hwnd); 3378 # ifdef FORTIFY 3379 Fortify_LeaveScope(); 3380 # endif 3367 3381 break; 3368 3382 } -
trunk/dll/collect.c
r1084 r1120 54 54 20 Jul 08 GKY Add save/append filename to clipboard. 55 55 Change menu wording to make these easier to find 56 25 Aug 08 GKY Check TMP directory space warn if lee than 5 MiB prevent archiver from opening if 57 less than 10 KiB (It hangs and can't be closed) 56 58 57 59 ***********************************************************************/ … … 1443 1445 if (mp1 && !IsFile((CHAR *)mp1)) 1444 1446 OpenDirCnr(HWND_DESKTOP, hwndMain, dcd->hwndFrame, FALSE, (PSZ) mp1); 1445 else if (mp1 && IsFile(mp1) == 1) 1447 else if (mp1 && IsFile(mp1) == 1 && 1448 CheckDriveSpaceAvail(ArcTempRoot, ullDATFileSpaceNeeded, ullTmpSpaceNeeded) != 2) 1446 1449 StartArcCnr(HWND_DESKTOP, 1447 1450 dcd->hwndFrame, (CHAR *)mp1, 4, (ARC_TYPE *) mp2); -
trunk/dll/defview.c
r985 r1120 18 18 20 Dec 07 GKY Open jpg files with OS2 object default since image.exe fails 19 19 29 Feb 08 GKY Refactor global command line variables to notebook.h 20 25 Aug 08 GKY Check TMP directory space warn if lee than 5 MiB prevent archiver from opening if 21 less than 10 KiB (It hangs and can't be closed) 20 22 21 23 ***********************************************************************/ … … 304 306 } 305 307 306 if (ExecAssociation(hwnd, filename) == -1) { 308 if (ExecAssociation(hwnd, filename) == -1 && 309 CheckDriveSpaceAvail(ArcTempRoot, ullDATFileSpaceNeeded, ullTmpSpaceNeeded) != 2) { 307 310 hwndArc = StartArcCnr((fExternalArcboxes || !swp || 308 311 strcmp(realappname, FM3Str)) ? -
trunk/dll/dircnrs.c
r1113 r1120 48 48 02 Aug 08 GKY Always pass temp variable point to treecnr UM_SHOWME to avoid 49 49 freeing dcd->directory early 50 25 Aug 08 GKY Check TMP directory space warn if lee than 5 MiB prevent archiver from opening if 51 less than 10 KiB (It hangs and can't be closed) 50 52 51 53 ***********************************************************************/ … … 1604 1606 OpenDirCnr(hwnd, dcd->hwndParent, dcd->hwndFrame, FALSE, (char *)mp1); 1605 1607 } 1606 else if (mp1 && IsFile(mp1) == 1) { 1608 else if (mp1 && IsFile(mp1) == 1 && 1609 CheckDriveSpaceAvail(ArcTempRoot, ullDATFileSpaceNeeded, ullTmpSpaceNeeded) != 2) { 1607 1610 StartArcCnr(HWND_DESKTOP, 1608 1611 dcd->hwndFrame, (CHAR *)mp1, 4, (ARC_TYPE *) mp2); -
trunk/dll/fm3dll.str
r1112 r1120 86 86 Dri~ves... 87 87 The target path %s will have less then %s bytes of space remaining following this operation. Do you wish to continue? 88 The TMP directory %s has l ess then %s of space. Do you wish to use the FM/2 save directory for temporary files? In any case you should free some space on this drive89 The TMP directory %s has less then %s of space & The FM/2 save directory %s has less then %s of space. You should free some space on these drives90 The FM2 save directory %s has l ess then %s of space. You should free some space on this drive91 The target path %s will have less then %s bytes of space remaining following this operation. You should free some space on this drive immediately88 The TMP directory %s has limited space remaining. Do you wish to use the FM/2 save directory for temporary files? In any case you should free some space on this drive 89 The TMP directory %s & the FM/2 save directory %s both have limited space remaining. You should free some space on these drives 90 The FM2 save directory %s has limited space remaining. You should free some space on this drive 91 FM/2's TMP and/or save directory has limited space remaining. You should free some space on this drive immediately 92 92 The target path %s has inadequate space remaining for the operation requested. Free some space and try again. 93 93 The TMP directory %s has limited space remaining. This will limit your ability to view large files. You should free some space on this drive 94 94 /OPEN 95 95 /CLOSE -
trunk/dll/fm3str.h
r1112 r1120 20 20 28 Jun 08 JBS Add string for warning message for changing/deleting FN2SHUTDOWN state 21 21 17 Jul 08 JBS "Renumbered" IDS_SHUTDOWNSTATE because its old numbers was "in use" 22 24 Aug 08 GKY Add strings for limited/inadequate drive space checks 22 23 23 24 ***********************************************************************/ … … 122 123 #define IDS_DRIVESPACELIMITEDTMPSAVE 90 123 124 #define IDS_DRIVESPACEEXCEEDED 91 125 #define IDS_ARCTMPDRIVESPACELIMITED 92 124 126 #define IDS_OPENCMDTEXT 93 125 127 #define IDS_CLOSECMDTEXT 94 -
trunk/dll/init.c
r1117 r1120 714 714 if (!ret) { //check writable 715 715 pTmpDir = xstrdup(szTempName, pszSrcFile, __LINE__); 716 } //fixme to check freespace > 5 MB716 } 717 717 } 718 718 } … … 725 725 pFM2SaveDirectory = xstrdup(temp, pszSrcFile, __LINE__); 726 726 } 727 // Check free space on TMP and FM2 Save drives 727 728 { 728 CHAR szKBTmp[20];729 730 729 ullTmpSpaceNeeded = 5120000; 731 CommaFmtULL(szKBTmp, sizeof(szKBTmp),732 ullTmpSpaceNeeded, 'M');733 printf("%s\r", szKBTmp); fflush(stdout);734 730 if (pTmpDir && CheckDriveSpaceAvail(pTmpDir, ullTmpSpaceNeeded, 0) == 1) { 735 731 if (CheckDriveSpaceAvail(pFM2SaveDirectory, ullTmpSpaceNeeded, 0) == 0){ … … 738 734 NullStr, 739 735 GetPString(IDS_TMPDRIVESPACELIMITED), 740 pTmpDir, 741 szKBTmp); 736 pTmpDir); 742 737 if (ret == MBID_YES) 743 738 pTmpDir = pFM2SaveDirectory; … … 749 744 GetPString(IDS_SAVETMPDRIVESPACELIMITED), 750 745 pTmpDir, 751 szKBTmp, 752 pFM2SaveDirectory, 753 szKBTmp); 746 pFM2SaveDirectory); 754 747 } 755 748 else if (CheckDriveSpaceAvail(pFM2SaveDirectory, ullTmpSpaceNeeded, 0) == 1) … … 758 751 NullStr, 759 752 GetPString(IDS_SAVEDRIVESPACELIMITED), 760 pFM2SaveDirectory, 761 szKBTmp); 753 pFM2SaveDirectory); 762 754 } 763 755 BldFullPathName(ArcTempRoot, pTmpDir, fAmAV2 ? "$AV$ARC$" : "$FM$ARC$"); -
trunk/dll/misc.c
r1118 r1120 2237 2237 CHAR szKB[20]; 2238 2238 2239 if (ullFreeSpaceWhenComplete == 0) 2240 ullSpaceNeeded = 0; 2241 commafmt(szKB, sizeof(szKB), 2242 (ULONG) ullFreeQty - ullSpaceNeeded); 2239 CommaFmtULL(szKB, sizeof(szKB), 2240 ullFreeQty - ullSpaceNeeded, ' '); 2243 2241 if (ullFreeSpaceWhenComplete == 0) { 2244 2242 saymsg(MB_OK, … … 2246 2244 NullStr, 2247 2245 GetPString(IDS_DRIVESPACELIMITEDTMPSAVE), 2248 pTargetPath, 2249 szKB); 2246 pTargetPath); 2250 2247 return 0; 2251 2248 }
Note:
See TracChangeset
for help on using the changeset viewer.