mirror of
https://gitea.wildfiregames.com/0ad/0ad.git
synced 2026-06-21 01:29:50 +00:00
Upgrade SpiderMonkey to version 45.0.2, refs #4893.
- Various build changes, in particular NSPR is not needed on Unix anymore - Add js/Initialization.h to source/scriptinterface/ScriptEngine.h - Use nullptr instead of JS::NullPtr(), see https://bugzilla.mozilla.org/show_bug.cgi?id=1164602 - Remove `JS::RuntimeOptionsRef.varObjFix`, see https://bugzilla.mozilla.org/show_bug.cgi?id=1171177 - Remove uses of `AutoIdArray`, see https://bugzilla.mozilla.org/show_bug.cgi?id=1191529 - `JS_InternUCStringN` has been renamed, see https://bugzilla.mozilla.org/show_bug.cgi?id=1178581 - `JS::Evaluate` now takes scope chains explicitly, see https://bugzilla.mozilla.org/show_bug.cgi?id=1097987 - Array functions (such as `JS_IsArrayObject`) are fallible and output to params, see https://bugzilla.mozilla.org/show_bug.cgi?id=f3d35d8 - Remove `JSCLASS_CACHED_PROTO_WIDTH` workaround in our code, see https://bugzilla.mozilla.org/show_bug.cgi?id=1236373 - Remove compile'n go (`setCompileAndGo`) and replace it by `setIsRunOnce` which will become the default in the future, see https://bugzilla.mozilla.org/show_bug.cgi?id=679939 - Mark shared memory in direct access operations (`JS_GetUint16ArrayData` and `JS_GetUint8ArrayData`), see https://bugzilla.mozilla.org/show_bug.cgi?id=1176214 - Use new `JS::ObjectOpResult`, see https://bugzilla.mozilla.org/show_bug.cgi?id=1113369 Thanks to wraitii, elexis, Krinkle and historic_bruno for contributions and comments, and to gentz, madpilot, s0600204 and Stan for testing and indirect contributions. Differential Revision: https://code.wildfiregames.com/D1510 This was SVN commit r22627.
This commit is contained in:
@@ -86,7 +86,8 @@ bool VisualReplay::ReadCacheFile(const ScriptInterface& scriptInterface, JS::Mut
|
||||
if (scriptInterface.ParseJSON(cacheStr, &cachedReplays))
|
||||
{
|
||||
cachedReplaysObject.set(&cachedReplays.toObject());
|
||||
if (JS_IsArrayObject(cx, cachedReplaysObject))
|
||||
bool isArray;
|
||||
if (JS_IsArrayObject(cx, cachedReplaysObject, &isArray) && isArray)
|
||||
return true;
|
||||
}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user