summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorLars Knoll <lars.knoll@digia.com>2013-04-05 23:45:15 +0200
committerSimon Hausmann <simon.hausmann@digia.com>2013-04-06 09:08:39 +0200
commit13650a052f910dd42e9b7936f055e15588bdc3a9 (patch)
tree512995a395c4a64ce8da508693c47cab1ce831ac
parent3b73dd08e0cb705dc57f6cce8b528c36aad40bcc (diff)
Fix scope for functions created through bind()
Change-Id: I69718b2943259dc0f6d6bf2856e651bfb4fbe3a5 Reviewed-by: Simon Hausmann <simon.hausmann@digia.com>
-rw-r--r--src/v4/qv4functionobject.cpp2
1 files changed, 1 insertions, 1 deletions
diff --git a/src/v4/qv4functionobject.cpp b/src/v4/qv4functionobject.cpp
index 91bff417..17b98246 100644
--- a/src/v4/qv4functionobject.cpp
+++ b/src/v4/qv4functionobject.cpp
@@ -301,7 +301,7 @@ Value FunctionPrototype::method_bind(CallContext *ctx)
boundArgs += ctx->argument(i);
- BoundFunction *f = ctx->engine->newBoundFunction(ctx, target, boundThis, boundArgs);
+ BoundFunction *f = ctx->engine->newBoundFunction(ctx->engine->rootContext, target, boundThis, boundArgs);
return Value::fromObject(f);
}