mirror of
https://github.com/reactos/reactos.git
synced 2025-08-04 19:26:29 +00:00
Disable incorrect optimization
svn path=/trunk/; revision=26055
This commit is contained in:
parent
136be81331
commit
88c1378112
1 changed files with 8 additions and 1 deletions
|
@ -620,6 +620,7 @@ VfatSetAllocationSizeInformation(PFILE_OBJECT FileObject,
|
||||||
}
|
}
|
||||||
else
|
else
|
||||||
{
|
{
|
||||||
|
#if 0 /* FIXME */
|
||||||
if (Fcb->LastCluster > 0)
|
if (Fcb->LastCluster > 0)
|
||||||
{
|
{
|
||||||
if (Fcb->RFCB.AllocationSize.u.LowPart - ClusterSize == Fcb->LastOffset)
|
if (Fcb->RFCB.AllocationSize.u.LowPart - ClusterSize == Fcb->LastOffset)
|
||||||
|
@ -656,6 +657,12 @@ VfatSetAllocationSizeInformation(PFILE_OBJECT FileObject,
|
||||||
Status = OffsetToCluster(DeviceExt, Cluster,
|
Status = OffsetToCluster(DeviceExt, Cluster,
|
||||||
ROUND_DOWN(NewSize - 1, ClusterSize) - Fcb->LastOffset,
|
ROUND_DOWN(NewSize - 1, ClusterSize) - Fcb->LastOffset,
|
||||||
&NCluster, TRUE);
|
&NCluster, TRUE);
|
||||||
|
#else
|
||||||
|
Status = OffsetToCluster(DeviceExt, FirstCluster,
|
||||||
|
ROUND_DOWN(NewSize - 1, ClusterSize),
|
||||||
|
&Cluster, TRUE);
|
||||||
|
NCluster = Cluster;
|
||||||
|
#endif
|
||||||
if (NCluster == 0xffffffff || !NT_SUCCESS(Status))
|
if (NCluster == 0xffffffff || !NT_SUCCESS(Status))
|
||||||
{
|
{
|
||||||
/* disk is full */
|
/* disk is full */
|
||||||
|
@ -678,7 +685,7 @@ VfatSetAllocationSizeInformation(PFILE_OBJECT FileObject,
|
||||||
{
|
{
|
||||||
AllocSizeChanged = TRUE;
|
AllocSizeChanged = TRUE;
|
||||||
/* FIXME: Use the cached cluster/offset better way. */
|
/* FIXME: Use the cached cluster/offset better way. */
|
||||||
Fcb->LastCluster = Fcb->LastCluster = 0;
|
Fcb->LastCluster = Fcb->LastOffset = 0;
|
||||||
UpdateFileSize(FileObject, Fcb, NewSize, ClusterSize);
|
UpdateFileSize(FileObject, Fcb, NewSize, ClusterSize);
|
||||||
if (NewSize > 0)
|
if (NewSize > 0)
|
||||||
{
|
{
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue