aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
-rw-r--r--src/qml/jsruntime/qv4functionobject.cpp4
-rw-r--r--src/qml/qml/qqmlboundsignal.cpp4
2 files changed, 4 insertions, 4 deletions
diff --git a/src/qml/jsruntime/qv4functionobject.cpp b/src/qml/jsruntime/qv4functionobject.cpp
index 172b29e88b..c65882ed7a 100644
--- a/src/qml/jsruntime/qv4functionobject.cpp
+++ b/src/qml/jsruntime/qv4functionobject.cpp
@@ -208,8 +208,10 @@ Heap::FunctionObject *FunctionObject::createQmlFunction(QQmlContextData *qmlCont
QV4::Scoped<QmlContext> wrapperContext(valueScope, QmlContext::create(global, qmlContext, scopeObject));
if (!signalParameters.isEmpty()) {
- if (error)
+ if (error) {
QQmlPropertyCache::signalParameterStringForJS(engine, signalParameters, error);
+ return 0;
+ }
runtimeFunction->updateInternalClass(engine, signalParameters);
}
diff --git a/src/qml/qml/qqmlboundsignal.cpp b/src/qml/qml/qqmlboundsignal.cpp
index 18d1e6bb4a..91b3f89825 100644
--- a/src/qml/qml/qqmlboundsignal.cpp
+++ b/src/qml/qml/qqmlboundsignal.cpp
@@ -122,10 +122,8 @@ QQmlBoundSignalExpression::QQmlBoundSignalExpression(QObject *target, int index,
QString error;
QV4::ExecutionEngine *engine = QQmlEnginePrivate::getV4Engine(ctxt->engine);
m_function.set(engine, QV4::FunctionObject::createQmlFunction(ctxt, scope, runtimeFunction, signal.parameterNames(), &error));
- if (!error.isEmpty()) {
+ if (!error.isEmpty())
qmlInfo(scopeObject()) << error;
- m_function.clear();
- }
}
void QQmlBoundSignalExpression::init(QQmlContextData *ctxt, QObject *scope)