gjs r88 - trunk/gjs



Author: tko
Date: Tue Nov 11 18:33:18 2008
New Revision: 88
URL: http://svn.gnome.org/viewvc/gjs?rev=88&view=rev

Log:
Reduce memory leakage during tests

	* gjs/jsapi-util-array.c (gjstest_test_func_gjs_jsapi_util_array):
	Shut down JS runtime at the end of the test to reduce memory
	leakage.

Modified:
   trunk/gjs/jsapi-util-array.c

Modified: trunk/gjs/jsapi-util-array.c
==============================================================================
--- trunk/gjs/jsapi-util-array.c	(original)
+++ trunk/gjs/jsapi-util-array.c	Tue Nov 11 18:33:18 2008
@@ -331,6 +331,10 @@
     }
 
     gjs_rooted_array_free(context, array, TRUE);
+
+    JS_DestroyContext(context);
+    JS_DestroyRuntime(runtime);
+    JS_ShutDown();
 }
 
 #endif /* GJS_BUILD_TESTS */



[Date Prev][Date Next]   [Thread Prev][Thread Next]   [Thread Index] [Date Index] [Author Index]