The tests crashed on my Debian systems but not on my Ubuntu system.
The crash happened in line 142 of SpiderMonkey's ThreadLocal.h.
I know that I had to use a workarounnd for contexts to avoid destroying
the context that was created first. I also had in mind that in newer
versions a JS_Init function got introduced which presumably solves this
kind of issues.
Based on this experience I assumed runtimes could have a similar problem
and this patch indeed fixes the issues.
Unfortunately the correct usage of JSRuntimes in that regard is not
documented.
There's only a rater misterious comment in JSAPI.h which hasn't been
cleared up so far and is most likely completely outdated
(https://bugzilla.mozilla.org/show_bug.cgi?id=992641).
This was SVN commit r14995.
This commit contains all the required changes to our source files and
build scripts (hopefully).
A next commit will remove the old stuff of SpiderMonkey 1.8.5.
Spcial thanks to:
- H4writer who helped a lot mainly with the performance issues we
had/have, but also with other problems or questions.
- Leper for the review.
- Historic_bruno for implementing the build scripts on Mac OS X and
testing on the Mac.
- The people from the #jsapi channel and from
mozilla.dev.tech.js-engine who answered a lot of questions and helped
solving problems.
- All the other people who helped
Refs #1886Fixes#2442Fixes#2416
This was SVN commit r14877.
I've tested the performance on Combat Demo (Huge) again with the code
from #2394.
It's very close but probably a little bit lower (hard to tell because
it's so close).
Closes#2408
Refs #2394
This was SVN commit r14705.
It's completely broken since 4b1297b328 and will have to be updated for
the new SpiderMonkey API.
I only uncomment it at the moment because I plan to fix/reimplement it
soon after the upgrade.
Closes#2348
Refs #2241
Refs #1886
This was SVN commit r14506.
Each GUI Page gets its own compartment and all ScriptInterfaces in the
same thread should now use the same JS Runtime.
This is required for the SpiderMonkey upgrade.
Check the ticket for details.
Closes#2241
Refs #1886
Refs #1966
This was SVN commit r14496.
Fix EncryptPassword being called with the wrong argument order, and
encrypting username instead of password. (This will break all existing
lobby accounts.)
Fix EncryptPassword not using all of salt_base.
This was SVN commit r14123.
Because it was historically grown, we have some duplicated code for
converting script types to native types.
This patch removes the file JSConversions.cpp and moves some code to
ScriptConversions.cpp.
The places using JSConversions.cpp are changed to use the
ScriptInterface's conversion functions in ScriptConversions.cpp.
I also removed JSInterface_Vector3D because it had additional
requirements to the conversion code that no other code has and because
it's currently not used. I think it doesn't make sense to maintain code
just because it could possibly be used again later.
Closes#2213
Refs #1886
This was SVN commit r14036.
Applies tech modifications to template data returned by GuiInterface.
Extends engine to load arbitrary global scripts, separates this from RNG
replacement. Refs #1193.
Loads global scripts for most script contexts for consistency.
Adds simulation tests for global scripts.
This was SVN commit r12056.