summaryrefslogtreecommitdiffstats
path: root/src
diff options
context:
space:
mode:
authorQt Continuous Integration System <qt-info@nokia.com>2011-02-22 14:51:58 (GMT)
committerQt Continuous Integration System <qt-info@nokia.com>2011-02-22 14:51:58 (GMT)
commit668499a22e7e5f166a001fe77dd709d24d0183ea (patch)
tree37610200f62b72721eb4029185ccc9977119b609 /src
parent928f6c74aa6f1915a7f8af6e874784e795859de9 (diff)
parente02d7079ca2851831c8a08e7c4994fe4428363ed (diff)
downloadQt-668499a22e7e5f166a001fe77dd709d24d0183ea.zip
Qt-668499a22e7e5f166a001fe77dd709d24d0183ea.tar.gz
Qt-668499a22e7e5f166a001fe77dd709d24d0183ea.tar.bz2
Merge branch '4.7' of scm.dev.nokia.troll.no:qt/oslo-staging-1 into 4.7-integration
* '4.7' of scm.dev.nokia.troll.no:qt/oslo-staging-1: Removing tabs from 7388fcb83592a90aace054314e0c3e7e7a94fdae changeset Fix QNetworkConfigurationManager crash due to null private pointer.
Diffstat (limited to 'src')
-rw-r--r--src/network/bearer/qnetworkconfigmanager.cpp17
1 files changed, 5 insertions, 12 deletions
diff --git a/src/network/bearer/qnetworkconfigmanager.cpp b/src/network/bearer/qnetworkconfigmanager.cpp
index 0e3c519..dc4e4f7 100644
--- a/src/network/bearer/qnetworkconfigmanager.cpp
+++ b/src/network/bearer/qnetworkconfigmanager.cpp
@@ -57,16 +57,17 @@ QT_BEGIN_NAMESPACE
{ \
delete this_##NAME.pointer; \
this_##NAME.pointer = 0; \
- this_##NAME.destroyed = true; \
} \
static TYPE *NAME() \
{ \
- if (!this_##NAME.pointer && !this_##NAME.destroyed) { \
+ if (!this_##NAME.pointer) { \
TYPE *x = new TYPE; \
if (!this_##NAME.pointer.testAndSetOrdered(0, x)) \
delete x; \
- else \
+ else { \
qAddPostRoutine(NAME##_cleanup); \
+ this_##NAME.pointer->updateConfigurations(); \
+ } \
} \
return this_##NAME.pointer; \
}
@@ -75,15 +76,7 @@ Q_GLOBAL_STATIC_QAPP_DESTRUCTION(QNetworkConfigurationManagerPrivate, connManage
QNetworkConfigurationManagerPrivate *qNetworkConfigurationManagerPrivate()
{
- static bool initialized = false;
-
- QNetworkConfigurationManagerPrivate *m = connManager();
- if (!initialized) {
- initialized = true;
- m->updateConfigurations();
- }
-
- return m;
+ return connManager();
}
/*!