Changeset 1438 for trunk/dll/worker.c
- Timestamp:
- Jun 28, 2009, 10:47:00 PM (16 years ago)
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/dll/worker.c
r1402 r1438 41 41 08 Mar 09 GKY Removed variable aurguments from docopyf and unlinkf (not used) 42 42 08 Mar 09 GKY Additional strings move to PCSZs 43 28 Jun 09 GKY Added AddBackslashToPath() to remove repeatative code. 43 44 44 45 ***********************************************************************/ … … 230 231 } 231 232 else 232 strcat(wk->li->targetpath, "\\");233 strcat(wk->li->targetpath, PCSZ_BACKSLASH); 233 234 sprintf(wk->li->targetpath + strlen(wk->li->targetpath), 234 235 "MERGE.%03x", (clock() & 4095L)); … … 708 709 GetPString(IDS_MOVEDTEXT) : GetPString(IDS_COPIEDTEXT); 709 710 if (*wk->li->targetpath) { 710 strcpy(newname, wk->li->targetpath); 711 if (newname[strlen(newname) - 1] != '\\') 712 strcat(newname, "\\"); 711 strcpy(newname, wk->li->targetpath); 712 AddBackslashToPath(newname); 713 //if (newname[strlen(newname) - 1] != '\\') 714 // strcat(newname, "\\"); 713 715 if (plen) 714 716 p = wk->li->list[x] + plen; … … 1209 1211 if (wk->li->type == IDM_MCIPLAY) 1210 1212 break; 1211 strcpy(szBuffer, wk->li->targetpath); 1212 if (wk->li->targetpath[strlen(wk->li->targetpath) - 1] != '\\') 1213 strcat(szBuffer, "\\"); 1213 strcpy(szBuffer, wk->li->targetpath); 1214 AddBackslashToPath(wk->li->targetpath); 1215 //if (wk->li->targetpath[strlen(wk->li->targetpath) - 1] != '\\') 1216 // strcat(szBuffer, "\\"); 1214 1217 p = szBuffer + strlen(szBuffer); 1215 1218 for (x = 0; wk->li->list[x]; x++) { … … 1270 1273 } 1271 1274 else { 1272 if (*wk->li->targetpath && !IsFile(wk->li->targetpath)) 1273 if (wk->li->targetpath[strlen(wk->li->targetpath) - 1] != 1274 '\\') 1275 strcat(wk->li->targetpath, "\\"); 1275 if (*wk->li->targetpath && !IsFile(wk->li->targetpath)) 1276 AddBackslashToPath(wk->li->targetpath); 1277 //if (wk->li->targetpath[strlen(wk->li->targetpath) - 1] != 1278 // '\\') 1279 // strcat(wk->li->targetpath, "\\"); 1276 1280 ad.namecanchange = 1; 1277 1281 } … … 1298 1302 break; 1299 1303 if (!*wk->li->targetpath && *wk->directory) { 1300 strcpy(ad.arcname, wk->directory); 1301 if (ad.arcname[strlen(ad.arcname) - 1] != '\\') 1302 strcat(ad.arcname, "\\"); 1304 strcpy(ad.arcname, wk->directory); 1305 AddBackslashToPath(ad.arcname); 1306 //if (ad.arcname[strlen(ad.arcname) - 1] != '\\') 1307 // strcat(ad.arcname, "\\"); 1303 1308 } 1304 1309 if (!WinDlgBox(HWND_DESKTOP, wk->hwndFrame, ArchiveDlgProc, FM3ModHandle, … … 1636 1641 wk->li-> 1637 1642 list[x][strlen(wk->li->list[x]) - 1] 1638 != '\\') ? "\\": NullStr);1643 != '\\') ? PCSZ_BACKSLASH : NullStr); 1639 1644 DosError(FERR_DISABLEHARDERR); 1640 1645 if (!error)
Note:
See TracChangeset
for help on using the changeset viewer.