Author: janderwald Date: Sat Feb 22 09:53:25 2014 New Revision: 62285
URL: http://svn.reactos.org/svn/reactos?rev=62285&view=rev Log: [KS] - Call Property handler guarded in seh block - Needs to be done in portcls too -
Modified: trunk/reactos/drivers/ksfilter/ks/property.c
Modified: trunk/reactos/drivers/ksfilter/ks/property.c URL: http://svn.reactos.org/svn/reactos/trunk/reactos/drivers/ksfilter/ks/propert... ============================================================================== --- trunk/reactos/drivers/ksfilter/ks/property.c [iso-8859-1] (original) +++ trunk/reactos/drivers/ksfilter/ks/property.c [iso-8859-1] Sat Feb 22 09:53:25 2014 @@ -7,6 +7,9 @@ */
#include "precomp.h" + +/* SEH support with PSEH */ +#include <pseh/pseh2.h>
#define NDEBUG #include <debug.h> @@ -280,8 +283,16 @@ KSPROPERTY_ITEM_IRP_STORAGE(Irp) = PropertyItem; }
- /* call property handler */ - Status = PropertyHandler(Irp, Property, (OutputBufferLength > 0 ? Irp->AssociatedIrp.SystemBuffer : NULL)); + _SEH2_TRY + { + /* call property handler */ + Status = PropertyHandler(Irp, Property, (OutputBufferLength > 0 ? Irp->AssociatedIrp.SystemBuffer : NULL)); + } + _SEH2_EXCEPT(EXCEPTION_EXECUTE_HANDLER) + { + _SEH2_YIELD(return _SEH2_GetExceptionCode()); + } + _SEH2_END;
if (Status == STATUS_BUFFER_TOO_SMALL) { @@ -297,9 +308,16 @@ /* no memory */ return STATUS_INSUFFICIENT_RESOURCES; } - - /* re-call property handler */ - Status = PropertyHandler(Irp, Property, Irp->AssociatedIrp.SystemBuffer); + _SEH2_TRY + { + /* re-call property handler */ + Status = PropertyHandler(Irp, Property, Irp->AssociatedIrp.SystemBuffer); + } + _SEH2_EXCEPT(EXCEPTION_EXECUTE_HANDLER) + { + Status = _SEH2_GetExceptionCode(); + } + _SEH2_END; } } }