1
0
mirror of https://github.com/rkd77/elinks.git synced 2025-02-02 15:09:23 -05:00

Bug 957: if_assert_failed in ecmascript_put_interpreter.

This commit is contained in:
Kalle Olavi Niemitalo 2007-07-02 21:43:30 +03:00 committed by Kalle Olavi Niemitalo
parent 13b1d26946
commit 566039624f

View File

@ -100,6 +100,10 @@ ecmascript_put_interpreter(struct ecmascript_interpreter *interpreter)
{
assert(interpreter);
assert(interpreter->backend_nesting == 0);
/* If the assertion fails, it is better to leak the
* interpreter than to corrupt memory. */
if_assert_failed return;
spidermonkey_put_interpreter(interpreter);
free_string_list(&interpreter->onload_snippets);
mem_free(interpreter);