Author: arty Date: Sat Sep 6 21:07:07 2008 New Revision: 36015
URL: http://svn.reactos.org/svn/reactos?rev=36015&view=rev Log: Add proper error case for buffer pin, spotted by aicom.
Modified: branches/arty-newcc/ntoskrnl/cache/pinsup.c
Modified: branches/arty-newcc/ntoskrnl/cache/pinsup.c URL: http://svn.reactos.org/svn/reactos/branches/arty-newcc/ntoskrnl/cache/pinsup... ============================================================================== --- branches/arty-newcc/ntoskrnl/cache/pinsup.c [iso-8859-1] (original) +++ branches/arty-newcc/ntoskrnl/cache/pinsup.c [iso-8859-1] Sat Sep 6 21:07:07 2008 @@ -660,6 +660,9 @@ FALSE, FALSE, NULL); + + if(!TheBcb->Pinned) return FALSE; + _SEH_TRY { MmProbeAndLockPages(TheBcb->Pinned, KernelMode, IoReadAccess); @@ -668,7 +671,7 @@ { IoFreeMdl(TheBcb->Pinned); TheBcb->Pinned = NULL; - Result = FALSE; + _SEH_YIELD(return FALSE); } _SEH_END; }