From 74be6cd70515891cdc642b9eafc14af267470102 Mon Sep 17 00:00:00 2001 From: Hartmut Birr Date: Wed, 10 Oct 2001 21:50:15 +0000 Subject: [PATCH] Added some initializations in CcRosInitializeCache(). svn path=/trunk/; revision=2277 --- reactos/ntoskrnl/cc/view.c | 7 ++++++- 1 file changed, 6 insertions(+), 1 deletion(-) diff --git a/reactos/ntoskrnl/cc/view.c b/reactos/ntoskrnl/cc/view.c index 8e6cf7ad6de..a490fd2b606 100644 --- a/reactos/ntoskrnl/cc/view.c +++ b/reactos/ntoskrnl/cc/view.c @@ -16,7 +16,7 @@ * along with this program; if not, write to the Free Software * Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA. */ -/* $Id: view.c,v 1.28 2001/09/02 15:38:46 dwelch Exp $ +/* $Id: view.c,v 1.29 2001/10/10 21:50:15 hbirr Exp $ * * COPYRIGHT: See COPYING in the top level directory * PROJECT: ReactOS kernel @@ -303,6 +303,11 @@ CcRosInitializeFileCache(PFILE_OBJECT FileObject, InitializeListHead(&(*Bcb)->CacheSegmentListHead); KeInitializeSpinLock(&(*Bcb)->BcbLock); (*Bcb)->CacheSegmentSize = CacheSegmentSize; + if (FileObject->FsContext) + { + (*Bcb)->AllocationSize = ((REACTOS_COMMON_FCB_HEADER*)FileObject->FsContext)->AllocationSize; + (*Bcb)->FileSize = ((REACTOS_COMMON_FCB_HEADER*)FileObject->FsContext)->FileSize; + } DPRINT("Finished CcRosInitializeFileCache() = %x\n", *Bcb);