From 29de67dff89763d69d1e04a9f4bfcdf1add5a883 Mon Sep 17 00:00:00 2001 From: Ykkrosh Date: Sat, 10 Jul 2004 12:56:17 +0000 Subject: [PATCH] Fixed potential memory leak This was SVN commit r681. --- source/simulation/scripting/JSInterface_Entity.cpp | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/source/simulation/scripting/JSInterface_Entity.cpp b/source/simulation/scripting/JSInterface_Entity.cpp index 43dae560ef..12152a63f3 100755 --- a/source/simulation/scripting/JSInterface_Entity.cpp +++ b/source/simulation/scripting/JSInterface_Entity.cpp @@ -116,7 +116,7 @@ JSBool JSI_Entity::construct( JSContext* cx, JSObject* obj, unsigned int argc, j void JSI_Entity::finalize( JSContext* cx, JSObject* obj ) { - delete( JS_GetPrivate( cx, obj ) ); + delete( (HEntity*)JS_GetPrivate( cx, obj ) ); } void JSI_Entity::init()