Changeset 66698 in vbox for trunk/src/VBox/Runtime
- Timestamp:
- Apr 27, 2017 3:48:29 PM (8 years ago)
- svn:sync-xref-src-repo-rev:
- 115091
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/src/VBox/Runtime/common/filesystem/fatvfs.cpp
r66691 r66698 1749 1749 { 1750 1750 PRTFSFATFILE pThis = (PRTFSFATFILE)pvThis; 1751 PRTFSFATVOL pVol = pThis->Core.pVol; 1751 1752 AssertReturn(pSgBuf->cSegs != 0, VERR_INTERNAL_ERROR_3); 1752 1753 RT_NOREF(fBlocking); 1754 1755 if (pVol->fReadOnly) 1756 return VERR_WRITE_PROTECT; 1753 1757 1754 1758 if (off == -1) … … 1790 1794 1791 1795 /* Figure the disk offset. */ 1792 uint64_t offDisk = rtFsFatChain_FileOffsetToDiskOff(&pThis->Core.Clusters, (uint32_t)off, p This->Core.pVol);1796 uint64_t offDisk = rtFsFatChain_FileOffsetToDiskOff(&pThis->Core.Clusters, (uint32_t)off, pVol); 1793 1797 if (offDisk != UINT64_MAX) 1794 1798 { 1795 rc = RTVfsFileWriteAt(p This->Core.pVol->hVfsBacking, offDisk, pbSrc, cbToWrite, NULL);1799 rc = RTVfsFileWriteAt(pVol->hVfsBacking, offDisk, pbSrc, cbToWrite, NULL); 1796 1800 if (RT_SUCCESS(rc)) 1797 1801 { … … 2650 2654 uint32_t *poffEntryInDir, uint32_t *pcFreeTail) 2651 2655 { 2656 /* First try make gcc happy. */ 2657 *pcFreeTail = 0; 2658 *poffEntryInDir = UINT32_MAX; 2659 2660 /* 2661 * Scan the whole directory, buffer by buffer. 2662 */ 2652 2663 uint32_t offStartFreeEntries = UINT32_MAX; 2653 2664 uint32_t cFreeEntries = 0; … … 2713 2724 rtFsFatDir_ReleaseBufferAfterReading(pThis, uBufferLock); 2714 2725 } 2715 2716 *pcFreeTail = cFreeEntries; 2717 *poffEntryInDir = UINT32_MAX; 2726 *pcFreeTail = cFreeEntries; 2718 2727 return VERR_DISK_FULL; 2719 2728 } … … 2849 2858 PRTFSFATVOL pVol = pThis->Core.pVol; 2850 2859 *poffEntryInDir = UINT32_MAX; 2860 if (pVol->fReadOnly) 2861 return VERR_WRITE_PROTECT; 2851 2862 2852 2863 /*
Note:
See TracChangeset
for help on using the changeset viewer.