Author: pschweitzer Date: Tue Oct 14 10:19:21 2008 New Revision: 36748
URL: http://svn.reactos.org/svn/reactos?rev=36748&view=rev Log: Fixed CcInitializeCacheMap to raise an exception when it fails to allocate memory. That way, bug #3351 were good, and will be applied.
Modified: branches/pierre-fsd/include/reactos/ccros.h branches/pierre-fsd/ntoskrnl/cc/view.c
Modified: branches/pierre-fsd/include/reactos/ccros.h URL: http://svn.reactos.org/svn/reactos/branches/pierre-fsd/include/reactos/ccros... ============================================================================== --- branches/pierre-fsd/include/reactos/ccros.h [iso-8859-1] (original) +++ branches/pierre-fsd/include/reactos/ccros.h [iso-8859-1] Tue Oct 14 10:19:21 2008 @@ -1,7 +1,7 @@ #ifndef __INCLUDE_DDK_NTIFS_H #define __INCLUDE_DDK_NTIFS_H
-NTSTATUS NTAPI +VOID NTAPI CcRosInitializeFileCache(PFILE_OBJECT FileObject, ULONG CacheSegmentSize, PCACHE_MANAGER_CALLBACKS CallBacks,
Modified: branches/pierre-fsd/ntoskrnl/cc/view.c URL: http://svn.reactos.org/svn/reactos/branches/pierre-fsd/ntoskrnl/cc/view.c?re... ============================================================================== --- branches/pierre-fsd/ntoskrnl/cc/view.c [iso-8859-1] (original) +++ branches/pierre-fsd/ntoskrnl/cc/view.c [iso-8859-1] Tue Oct 14 10:19:21 2008 @@ -1238,7 +1238,7 @@ }
-NTSTATUS NTAPI +VOID NTAPI CcRosInitializeFileCache(PFILE_OBJECT FileObject, ULONG CacheSegmentSize, PCACHE_MANAGER_CALLBACKS CallBacks, @@ -1260,7 +1260,7 @@ if (Bcb == NULL) { KeReleaseGuardedMutex(&ViewLock); - return(STATUS_UNSUCCESSFUL); + ExRaiseStatus(STATUS_INSUFFICIENT_RESOURCES); } memset(Bcb, 0, sizeof(BCB)); ObReferenceObjectByPointer(FileObject, @@ -1293,8 +1293,6 @@ Bcb->BcbRemoveListEntry.Flink = NULL; } KeReleaseGuardedMutex(&ViewLock); - - return(STATUS_SUCCESS); }
/*