summaryrefslogtreecommitdiffstats
path: root/examples/qml/networkaccessmanagerfactory/main.cpp
diff options
context:
space:
mode:
Diffstat (limited to 'examples/qml/networkaccessmanagerfactory/main.cpp')
-rw-r--r--examples/qml/networkaccessmanagerfactory/main.cpp3
1 files changed, 2 insertions, 1 deletions
diff --git a/examples/qml/networkaccessmanagerfactory/main.cpp b/examples/qml/networkaccessmanagerfactory/main.cpp
index 95dfb5990d..a0fddf50c6 100644
--- a/examples/qml/networkaccessmanagerfactory/main.cpp
+++ b/examples/qml/networkaccessmanagerfactory/main.cpp
@@ -133,7 +133,8 @@ int main(int argc, char ** argv)
source = QUrl::fromLocalFile(parser.positionalArguments().first());
QQuickView view;
- view.engine()->setNetworkAccessManagerFactory(new MyNetworkAccessManagerFactory);
+ MyNetworkAccessManagerFactory networkManagerFactory;
+ view.engine()->setNetworkAccessManagerFactory(&networkManagerFactory);
view.setSource(source);
view.show();