Update NTOSKRNL/CC/ccpinsupport.cpp
Loop was prematurely terminating due to wrong condition of if(BeyondLastByte.QuadPart < LocalFileOffset.QuadPart + RemainingLength) we are mapping across the length, itroduced some guard checks if(localbcb != nullptr) { CcSetDirtyPinnedData(localbcb, nullptr); *Bcb = localbcb; } to fix some test case where it was failing
This commit is contained in:
parent
10527bf405
commit
47bfb48ebb
@ -795,7 +795,7 @@ CcPreparePinWrite(
|
||||
}
|
||||
return false;
|
||||
}
|
||||
if(BeyondLastByte.QuadPart < LocalFileOffset.QuadPart + RemainingLength)
|
||||
if(BeyondLastByte.QuadPart > LocalFileOffset.QuadPart + RemainingLength)
|
||||
break;
|
||||
|
||||
}
|
||||
@ -810,8 +810,11 @@ CcPreparePinWrite(
|
||||
RtlZeroMemory(*Buffer, Length);
|
||||
}
|
||||
|
||||
if(localbcb != nullptr)
|
||||
{
|
||||
CcSetDirtyPinnedData(localbcb, nullptr);
|
||||
*Bcb = localbcb;
|
||||
}
|
||||
|
||||
return true;
|
||||
}
|
||||
|
Loading…
Reference in New Issue
Block a user