summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorRay Strode <rstrode@redhat.com>2018-03-23 15:22:59 -0400
committerRay Strode <rstrode@redhat.com>2018-04-03 14:16:26 -0400
commitc348eef7b10ad896280fe8399183846ec8ab4ceb (patch)
treef687b8746019186a67b6d13f8fe5aac5b681c986
parenta1a66f2ecbae005a77fa3a2305e8cde6bf67d545 (diff)
downloadpolkit-c348eef7b10ad896280fe8399183846ec8ab4ceb.tar.gz
jsauthority: call JS_InitSelfHostedCode
This is now required Signed-off-by: Ray Strode <rstrode@redhat.com> https://bugs.freedesktop.org/show_bug.cgi?id=105865
-rw-r--r--src/polkitbackend/polkitbackendjsauthority.cpp3
1 files changed, 3 insertions, 0 deletions
diff --git a/src/polkitbackend/polkitbackendjsauthority.cpp b/src/polkitbackend/polkitbackendjsauthority.cpp
index 7e98adb..9fe151b 100644
--- a/src/polkitbackend/polkitbackendjsauthority.cpp
+++ b/src/polkitbackend/polkitbackendjsauthority.cpp
@@ -458,6 +458,9 @@ polkit_backend_js_authority_constructed (GObject *object)
if (authority->priv->cx == NULL)
goto fail;
+ if (!JS::InitSelfHostedCode (authority->priv->cx))
+ goto fail;
+
/* TODO: JIT'ing doesn't work will with killing runaway scripts... I think
* this is just a SpiderMonkey bug. So disable the JIT for now.
*/