Merge lp:~mardy/signon-ui/lp1053444 into lp:signon-ui

Proposed by Alberto Mardegan
Status: Merged
Approved by: David King
Approved revision: 64
Merged at revision: 64
Proposed branch: lp:~mardy/signon-ui/lp1053444
Merge into: lp:signon-ui
Diff against target: 14 lines (+2/-2)
1 file modified
src/main.cpp (+2/-2)
To merge this branch: bzr merge lp:~mardy/signon-ui/lp1053444
Reviewer Review Type Date Requested Status
jenkins (community) continuous-integration Needs Fixing
David King (community) Approve
Review via email: mp+126161@code.launchpad.net

Description of the change

Do not allocate the proxy factory on the stack

QNetworkProxyFactory::setApplicationProxyFactory() is documented to take
ownership of the proxy factory and destroy it (with "delete") when destructed.

To post a comment you must log in.
Revision history for this message
David King (amigadave) wrote :

Simple fix.

review: Approve
Revision history for this message
jenkins (martin-mrazik+qa) wrote :
review: Needs Fixing (continuous-integration)

Preview Diff

[H/L] Next/Prev Comment, [J/K] Next/Prev File, [N/P] Next/Prev Hunk
1=== modified file 'src/main.cpp'
2--- src/main.cpp 2012-09-14 10:14:14 +0000
3+++ src/main.cpp 2012-09-25 06:16:20 +0000
4@@ -62,8 +62,8 @@
5 /* Use a libproxy-based proxy factory; this code will no longer be
6 * needed when https://bugreports.qt-project.org/browse/QTBUG-26295
7 * is fixed. */
8- MyNetworkProxyFactory proxyFactory;
9- QNetworkProxyFactory::setApplicationProxyFactory(&proxyFactory);
10+ MyNetworkProxyFactory *proxyFactory = new MyNetworkProxyFactory();
11+ QNetworkProxyFactory::setApplicationProxyFactory(proxyFactory);
12
13 Service *service = new Service();
14 if (daemonTimeout > 0)

Subscribers

People subscribed via source and target branches

to all changes: