Closed
Bug 482203
Opened 16 years ago
Closed 16 years ago
NullPointerException capturing a continuation
Categories
(Rhino Graveyard :: Core, defect)
Tracking
(Not tracked)
RESOLVED
FIXED
People
(Reporter: szegedia, Unassigned)
Details
Attachments
(1 file)
|
1.62 KB,
application/zip
|
Details |
Up to 1.7R1, I used to terminate an interpreter by capturing a continuation at the top scope level, and then invoking it when necessary. With HEAD though, now I'm getting a NullPointerException:
Exception in thread "main" java.lang.NullPointerException
at org.mozilla.javascript.Interpreter.captureContinuation(Interpreter.java:2945)
at org.mozilla.javascript.Interpreter.interpretLoop(Interpreter.java:1729)
at org.mozilla.javascript.Interpreter.interpret(Interpreter.java:845)
at org.mozilla.javascript.InterpretedFunction.call(InterpretedFunction.java:164)
at org.mozilla.javascript.ContextFactory.doTopCall(ContextFactory.java:405)
at org.mozilla.javascript.ScriptRuntime.doTopCall(ScriptRuntime.java:3066)
at org.mozilla.javascript.Context.callFunctionWithContinuations(Context.java:1199)
at org.mozilla.javascript.Context.executeScriptWithContinuations(Context.java:1166)
at org.szegedi.rhinotest.ContinuationsTest17.main(ContinuationsTest17.java:20)
I've attached a ZIP file with two Java test files and one .js file - the first Java class (suffixed 16) works against all 1.6 Rhino releases that support continuations, as well as 1.7R1. The second Java class (suffixed 17) uses the 1.7R2 continuations API, and throws a NPE.
Is this a bug, or am I doing something wrong?
| Reporter | ||
Comment 1•16 years ago
|
||
Comment 2•16 years ago
|
||
Fixed:
Checking in src/org/mozilla/javascript/Interpreter.java;
/cvsroot/mozilla/js/rhino/src/org/mozilla/javascript/Interpreter.java,v <-- In
terpreter.java
new revision: 1.355; previous revision: 1.354
done
RCS file: /cvsroot/mozilla/js/rhino/testsrc/org/mozilla/javascript/tests/Bug4822
03.java,v
done
Checking in testsrc/org/mozilla/javascript/tests/Bug482203.java;
/cvsroot/mozilla/js/rhino/testsrc/org/mozilla/javascript/tests/Bug482203.java,v
<-- Bug482203.java
initial revision: 1.1
done
and in release branch:
Checking in src/org/mozilla/javascript/Interpreter.java;
/cvsroot/mozilla/js/rhino/src/org/mozilla/javascript/Interpreter.java,v <-- Interpreter.java
new revision: 1.349.2.5; previous revision: 1.349.2.4
done
Status: NEW → RESOLVED
Closed: 16 years ago
Resolution: --- → FIXED
You need to log in
before you can comment on or make changes to this bug.
Description
•