Changeset 1351 for trunk/dll/worker.c
- Timestamp:
- Dec 21, 2008, 12:41:07 AM (17 years ago)
- File:
-
- 1 edited
-
trunk/dll/worker.c (modified) (13 diffs)
Legend:
- Unmodified
- Added
- Removed
-
trunk/dll/worker.c
r1335 r1351 911 911 &files, &numfiles, &numalloc)) 912 912 Broadcast(hab2, 913 wk->hwndCnr,913 wk->hwndCnr, 914 914 UM_UPDATERECORD, 915 MPFROMP(wk->li->list[x]), MPVOID);915 MPFROMP(wk->li->list[x]), MPVOID); 916 916 if (//fSyncUpdates || 917 917 AddToList(newname, &files, &numfiles, &numalloc)) 918 918 Broadcast(hab2, 919 wk->hwndCnr,920 UM_UPDATERECORD, MPFROMP(newname), MPVOID);919 wk->hwndCnr, 920 UM_UPDATERECORD, MPFROMP(newname), MPVOID); 921 921 } 922 922 } … … 926 926 case IDM_COMPARE: 927 927 if ((!IsFile(wk->li->targetpath) || 928 IsRoot(wk->li->targetpath)) &&928 IsRoot(wk->li->targetpath)) && 929 929 (!IsFile(wk->li->list[x]) || IsRoot(wk->li->list[x]))) { 930 930 if (!*dircompare && WinIsWindow(hab2, wk->hwndCnr)) … … 1022 1022 Broadcast(hab2, 1023 1023 wk->hwndCnr, 1024 UM_UPDATERECORDLIST, MPFROMP(files), MPVOID); 1024 UM_UPDATERECORDLIST, MPFROMP(files), MPVOID); 1025 // DbgMsg(pszSrcFile, __LINE__, "UM_UPDATERECORD %s", *files); 1025 1026 FreeList(files); 1026 1027 } … … 1088 1089 Broadcast(hab2, 1089 1090 wk->hwndCnr, 1090 UM_UPDATERECORDLIST, MPFROMP(wk->li->list), MPVOID);1091 UM_UPDATERECORDLIST, MPFROMP(wk->li->list), MPVOID); 1091 1092 break; 1092 1093 … … 1211 1212 Broadcast(hab2, 1212 1213 wk->hwndCnr, 1213 UM_UPDATERECORDLIST, MPFROMP(wk->li->list), MPVOID);1214 UM_UPDATERECORDLIST, MPFROMP(wk->li->list), MPVOID); 1214 1215 } 1215 1216 break; … … 1231 1232 Broadcast(hab2, 1232 1233 wk->hwndCnr, 1233 UM_UPDATERECORD, MPFROMP(wk->li->targetpath), MPVOID);1234 UM_UPDATERECORD, MPFROMP(wk->li->targetpath), MPVOID); 1234 1235 } 1235 1236 break; … … 1500 1501 Broadcast(hab2, 1501 1502 wk->hwndCnr, 1502 UM_UPDATERECORDLIST, MPFROMP(wk->li->list), MPVOID);1503 UM_UPDATERECORDLIST, MPFROMP(wk->li->list), MPVOID); 1503 1504 } 1504 1505 break; … … 1515 1516 HOBJECT hObjectdest, hObjectofObject; 1516 1517 BYTE G_abSupportedDrives[24] = {0}; 1517 ULONG cbSupportedDrives = sizeof(G_abSupportedDrives);1518 ULONG cbSupportedDrives = sizeof(G_abSupportedDrives); 1518 1519 1519 1520 for (x = 0; wk->li->list[x]; x++) { … … 1619 1620 &fsa, (ULONG) sizeof(FILESTATUS3)); 1620 1621 if (fsa.attrFile & FILE_DIRECTORY) { 1621 /*sprintf(prompt,1622 GetPString(IDS_DELETINGTEXT), wk->li->list[x]);1623 AddNote(prompt);*/ //Duplicate call 12-03-08 GKY1624 DosRequestMutexSem(hmtxFM2Delete, SEM_INDEFINITE_WAIT); // Prevent race 12-3-08 GKY1625 1622 error = (APIRET) wipeallf("%s%s*", 1626 1623 wk->li->list[x], … … 1634 1631 else 1635 1632 DosDeleteDir(wk->li->list[x]); 1636 DosReleaseMutexSem(hmtxFM2Delete); 1637 } 1638 else { 1639 DosRequestMutexSem(hmtxFM2Delete, SEM_INDEFINITE_WAIT); // Prevent race 12-3-08 1640 /*sprintf(prompt, 1641 GetPString(IDS_DELETINGTEXT), wk->li->list[x]); 1642 AddNote(prompt); */ //Duplicate call 12-03-08 GKY 1633 } 1634 else { 1635 1643 1636 DosError(FERR_DISABLEHARDERR); 1644 if (wk->li->type == IDM_DELETE) {1637 if (wk->li->type == IDM_DELETE) { 1645 1638 hObjectdest = WinQueryObject("<XWP_TRASHCAN>"); 1646 1639 PrfQueryProfileData(HINI_USER, … … 1658 1651 error = WinMoveObject(hObjectofObject, hObjectdest, 0); 1659 1652 } 1660 else { 1661 //DosRequestMutexSem(hmtxFM2Delete, SEM_INDEFINITE_WAIT); // Prevent race 12-3-08 GKY 1662 error = DosDelete(wk->li->list[x]); 1663 //DosReleaseMutexSem(hmtxFM2Delete); 1653 else { 1654 error = DosDelete(wk->li->list[x]); 1664 1655 } 1665 1656 } 1666 else { 1667 //DosRequestMutexSem(hmtxFM2Delete, SEM_INDEFINITE_WAIT); // Prevent race 12-3-08 GKY 1668 error = DosForceDelete(wk->li->list[x]); 1669 //DosReleaseMutexSem(hmtxFM2Delete); 1670 } 1671 if (error) { 1672 DosError(FERR_DISABLEHARDERR); 1657 else { 1658 error = DosForceDelete(wk->li->list[x]); ; 1659 } 1660 if (error) { 1661 DosError(FERR_DISABLEHARDERR); 1673 1662 make_deleteable(wk->li->list[x]); 1674 1663 if (wk->li->type == IDM_DELETE){ … … 1688 1677 error = WinMoveObject(hObjectofObject, hObjectdest, 0); 1689 1678 } 1690 else { 1691 // DosRequestMutexSem(hmtxFM2Delete, SEM_INDEFINITE_WAIT); // Prevent race 12-3-08 GKY 1692 error = DosDelete(wk->li->list[x]); 1693 // DosReleaseMutexSem(hmtxFM2Delete); 1679 else { 1680 error = DosDelete(wk->li->list[x]); 1694 1681 } 1695 1682 } 1696 else { 1697 //DosRequestMutexSem(hmtxFM2Delete, SEM_INDEFINITE_WAIT); // Prevent race 12-3-08 GKY 1698 error = DosForceDelete(wk->li->list[x]); 1699 //DosReleaseMutexSem(hmtxFM2Delete); 1683 else { 1684 error = DosForceDelete(wk->li->list[x]); 1700 1685 } 1701 1686 } … … 1738 1723 Broadcast(hab2, 1739 1724 wk->hwndCnr, 1740 UM_UPDATERECORDLIST, MPFROMP(files), MPVOID);1725 UM_UPDATERECORDLIST, MPFROMP(files), MPVOID); 1741 1726 FreeList(files); 1742 1727 }
Note:
See TracChangeset
for help on using the changeset viewer.
