In the changes for mozjs-24, I forgot a NULL check.
isJSAlive should return false if cw->jss is unallocated, rather
than dereferencing NULL!
---
 src/jsdom.cpp | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/src/jsdom.cpp b/src/jsdom.cpp
index a37eaec..5a60895 100644
--- a/src/jsdom.cpp
+++ b/src/jsdom.cpp
@@ -61,7 +61,7 @@ my_ErrorReporter(JSContext * cx, const char *message, 
JSErrorReport * report)
 eb_bool
 isJSAlive(void)
 {
-    return cw->jss->jcx != NULL;
+    return (cw->jss != NULL) && (cw->jss->jcx != NULL);
 }                              /* isJSAlive */
 
 JSString *
-- 
1.8.3.2

_______________________________________________
Edbrowse-dev mailing list
[email protected]
http://lists.the-brannons.com/mailman/listinfo/edbrowse-dev

Reply via email to