From a45dd7648b64dce375e5167c904633090e97a60e Mon Sep 17 00:00:00 2001 From: mittorn Date: Sat, 20 Oct 2018 21:56:40 +0700 Subject: [PATCH] Add null pointer check --- dlls/xen.cpp | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/dlls/xen.cpp b/dlls/xen.cpp index 1d86beb3..9d0ffb18 100644 --- a/dlls/xen.cpp +++ b/dlls/xen.cpp @@ -233,7 +233,8 @@ void CXenTreeTrigger::Touch( CBaseEntity *pOther ) if( pev->owner ) { CBaseEntity *pEntity = CBaseEntity::Instance( pev->owner ); - pEntity->Touch( pOther ); + if( pEntity ) + pEntity->Touch( pOther ); } }