summaryrefslogtreecommitdiffstats
path: root/src/network
Commit message (Collapse)AuthorAgeFilesLines
* Use qEnvironmentVariableIntValue() instead of qgetenv().toInt().Sérgio Martins2015-12-181-2/+2
| | | | | | | It's much faster. Change-Id: I55e0a23f9086fe2e7872e81dc0f5e10105ed124a Reviewed-by: Marc Mutz <marc.mutz@kdab.com>
* Merge remote-tracking branch 'origin/5.6' into devLiang Qi2015-12-186-12/+41
|\ | | | | | | | | | | | | | | | | | | | | | | Conflicts: src/gui/painting/painting.pri src/plugins/platforms/xcb/qxcbconnection.cpp tests/auto/corelib/thread/qthreadstorage/qthreadstorage.pro tests/auto/corelib/tools/qlocale/test/test.pro tests/auto/gui/kernel/qwindow/tst_qwindow.cpp tools/configure/environment.cpp Change-Id: I9c40f458b89b2c206de2d2c24e90b5f679c93495
| * QtNetwork: Standardize error message about IPv6 addresses for nameservers.v5.6.0-beta1Friedemann Kleint2015-12-144-4/+9
| | | | | | | | | | | | | | | | Add a const char * message with QDnsLookupRunnable's translation context and use that for untranslated warnings and errorString. Change-Id: I1b6c9fb259fb9ff824a0c3829b2c00c36aaecdfa Reviewed-by: Richard J. Moore <rich@kde.org>
| * Align signature with generic native socket engineMaurice Kalinowski2015-12-091-1/+1
| | | | | | | | | | | | | | | | | | | | This allows to use readDatagram on WinRT like on any other platform, ie using two arguments. Fixes compilation in auto-tests. Change-Id: I4a6e34dc72d2845faab9067ce67800d8b386c344 Reviewed-by: Oliver Wolff <oliver.wolff@theqtcompany.com>
| * QNetworkInterface: fix support for address labels on Linux interfacesThiago Macieira2015-12-081-7/+31
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Commit 64a1448d87727878d9789906b2f4f5b9e3d74e38 (Qt 5.2) caused QNetworkInterface to report address labels (a.k.a. interface aliases) as separate interfaces. This is caused by the fact that glibc, uClibc and MUSL copy the address label (netlink address attribute IFA_LABEL) to the ifa_name field, which made QNetworkInterfaceManager think that it was an interface it hadn't yet seen. Address labels are the old way to add more than one IP address to an interface on Linux, for example: ifconfig eth0:1 192.0.2.2 Those do not create a new interface, so the "eth0:1" label maps to the same interface index as the parent interface. This has been deprecated for 10 years, but there are still tools out there that add addresses in this manner. This commit restores behavior compatibility with Qt 4.2-5.1. The Qt 5.2-5.5 behavior is incorrect because it reports more than one interface with the same index. On systems configured like the above, the tst_QNetworkInterface::interfaceFromXXX test was failing. Change-Id: I8de47ed6c7be4847b99bffff141c2d9de8cf7329 Reviewed-by: Richard J. Moore <rich@kde.org>
* | network: Pass types with copy-ctor or dtor by const-refSérgio Martins2015-12-1310-22/+21
| | | | | | | | | | Change-Id: I7bea3e03bff6f424b02335476211dd466ce4d720 Reviewed-by: Marc Mutz <marc.mutz@kdab.com>
* | Haiku: Fix compilation of network libraryTobias Koenig2015-12-081-0/+4
| | | | | | | | | | | | | | | | | | Like on some BSD systems, the member of the ifreq structure is called ifr_index and not ifr_ifindex on Haiku OS. Change-Id: I273de0c703b1c89dbac537c68e52db219d2da50e Reviewed-by: Thiago Macieira <thiago.macieira@intel.com>
* | Merge remote-tracking branch 'origin/5.6' into devSimon Hausmann2015-12-082-4/+6
|\| | | | | | | Change-Id: I2532c7f7db5e6cc3ef09753d886279816dd662b2
| * WinRT: Set TemporaryError in QNativeSocketEngine::accept() when no ↵Friedemann Kleint2015-12-071-1/+3
| | | | | | | | | | | | | | | | | | | | | | | | connections are pending. This suppresses the emission of QTcpServer::acceptError() from QTcpServerPrivate::readNotification(). Task-number: QTBUG-49776 Change-Id: Icfb686d44c0a396ae2bf5867bd31a91232ef3e3c Reviewed-by: Markus Goetz (Woboq GmbH) <markus@woboq.com> Reviewed-by: Oliver Wolff <oliver.wolff@theqtcompany.com>
| * Doc: Added missing semicolons to snippetNico Vertriest2015-12-031-3/+3
| | | | | | | | | | | | Task-number: QTBUG-34594 Change-Id: I3eeff4494f5b27c5b34b911008b1a87abe032868 Reviewed-by: Topi Reiniö <topi.reinio@theqtcompany.com>
* | Properly set (sa|sin|sin6)_len on Unix systems that need itThiago Macieira2015-12-052-0/+14
| | | | | | | | | | Change-Id: I7de033f80b0e4431b7f1ffff13f90288a50606e7 Reviewed-by: Richard J. Moore <rich@kde.org>
* | Merge remote-tracking branch 'origin/5.6' into devLiang Qi2015-12-0211-139/+385
|\| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Conflicts: src/corelib/kernel/qcoreapplication.cpp src/corelib/kernel/qeventdispatcher_blackberry.cpp src/network/bearer/qnetworkconfiguration.cpp src/plugins/bearer/blackberry/qbbengine.cpp src/plugins/platforms/android/androidjnimain.cpp src/plugins/platforms/android/qandroidplatformtheme.cpp src/plugins/platforms/qnx/qqnxbpseventfilter.cpp src/plugins/platforms/qnx/qqnxfiledialoghelper_bb10.cpp src/plugins/platforms/qnx/qqnxinputcontext_imf.cpp src/plugins/platforms/qnx/qqnxintegration.cpp src/plugins/platforms/qnx/qqnxnavigatorbps.cpp src/plugins/platforms/qnx/qqnxvirtualkeyboardbps.cpp src/plugins/platforms/qnx/qqnxwindow.cpp src/widgets/kernel/qwidgetwindow.cpp src/widgets/styles/qwindowsvistastyle.cpp src/widgets/styles/qwindowsxpstyle.cpp src/widgets/widgets/qtoolbararealayout.cpp tests/auto/corelib/global/qflags/qflags.pro tests/auto/corelib/itemmodels/qitemmodel/modelstotest.cpp tests/auto/corelib/tools/qversionnumber/qversionnumber.pro tests/auto/widgets/dialogs/qfilesystemmodel/tst_qfilesystemmodel.cpp Change-Id: I37be88c6c185bb85404823353e027a0a6acdbce4
| * QDnsLookup: fix grammar in a user-visible stringMarc Mutz2015-11-281-2/+2
| | | | | | | | | | Change-Id: I6bda83c750d2e2c0a2325aae259836bb96d92a11 Reviewed-by: Friedemann Kleint <Friedemann.Kleint@theqtcompany.com>
| * QNAM Fix error messageDaniel Molkentin2015-11-281-2/+2
| | | | | | | | | | | | | | | | | | | | The code path is called for up- and downloads, yet the error message talks about "Error downloading...". Make this "Error transferring..." for a more neutral statement. Change-Id: Ifbca6a95058042b195cdbeec339ef27a231491b2 Reviewed-by: Simon Hausmann <simon.hausmann@theqtcompany.com>
| * QtBase: remove explicit function info from qWarning() etcMarc Mutz2015-11-285-21/+21
| | | | | | | | | | | | | | | | | | | | | | This information is already registered by the QMessageLogger ctor. Where, by dropping the << Q_FUNC_INFO in ostream-style qDebug(), only a string literal remained, converted to printf-style qDebug() on the go. Change-Id: I3f261c98fd7bcfa1fead381a75a82713bb75e6f3 Reviewed-by: Olivier Goffart (Woboq GmbH) <ogoffart@woboq.com>
| * Merge "Merge remote-tracking branch 'origin/5.5' into 5.6" into refs/staging/5.6Liang Qi2015-11-274-113/+336
| |\
| | * Merge remote-tracking branch 'origin/5.5' into 5.6Liang Qi2015-11-274-113/+336
| | |\ | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Conflicts: src/network/socket/qnativesocketengine_p.h src/network/ssl/qsslsocket_mac.cpp src/network/ssl/qsslsocket_mac_p.h src/widgets/kernel/qwidget.cpp Change-Id: I39592cb37d710dfaf8640769ba3c1b637927d7f4
| | | * Secure Transport - make it work on OS X 10.7Timur Pocheptsov2015-11-231-79/+212
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | SSLSetProtocolVersionMin/Max were introduced _only_ in 10.8 and we need a workaround for 10.7 - use SSLSetProtocolVersion or SSLSetProtocolVersionEnabled. Change-Id: I4b7ed9fda21e2c374a98fd777253280e8013ffde Reviewed-by: Morten Johan Sørvig <morten.sorvig@theqtcompany.com>
| | | * Secure Transport backend - make it work on OS X 10.7Timur Pocheptsov2015-11-232-13/+103
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | On OS X SSLCreateContext is quite recent - it requires OS X/SDK version >= 10.8. Since SecureTransport back-end is the default one in Qt 5.6, make it also work on OS X 10.7. Change-Id: I364feff9dd95772fcea926494b2d4edaffd2dde1 Reviewed-by: Morten Johan Sørvig <morten.sorvig@theqtcompany.com>
| | | * Fix build with 'udpsocket' feature disabledAlex Trotsenko2015-11-142-22/+26
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Wrap related code in QNativeSocketEngine and the tuiotouch plugin in conditionals. Change-Id: Ic6861b1c6a9e041fa8a50f96149f7280473a9fba Reviewed-by: Oswald Buddenhagen <oswald.buddenhagen@theqtcompany.com> Reviewed-by: Friedemann Kleint <Friedemann.Kleint@theqtcompany.com> Reviewed-by: Thiago Macieira <thiago.macieira@intel.com>
| | | * Don't let closed http sockets pass as valid connectionsUlf Hermann2015-11-051-1/+6
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | A QAbstractSocket can be close()'d at any time, independently of its current connection state. being closed means that we cannot use it to read or write data, but internally it might still have some data to send or receive, for example to an http server. We can even get a connected() signal after close()'ing the socket. We need to catch this condition and mark any pending data not yet written to the socket for resending. (cherry picked from commit 0df5d079290b4c3b13e58e9397fabdc1dfdba96b) Task-number: QTBUG-48326 Change-Id: I67d9ad36f7288c9c6bef51aa6253d7b187737601 Reviewed-by: Ulf Hermann <ulf.hermann@theqtcompany.com> Reviewed-by: Markus Goetz (Woboq GmbH) <markus@woboq.com>
| * | | winrt: Make error messages of QNativeSocketEngine more verbose.Friedemann Kleint2015-11-271-7/+28
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Output function, object name and class of the socket. Example: qt.winrtrunner.app: handleReadyRead(): Could not read into socket stream buffer ("QTcpServer:40000"/QTcpServer). (A method was called at an unexpected time.) Change-Id: Ic074c2c3a01221bd77dae0715db912e830f21435 Reviewed-by: Oliver Wolff <oliver.wolff@theqtcompany.com>
| * | | Do not try to connect to null object if bearer plugin is missingJoni Poikelin2015-11-271-2/+4
| |/ / | | | | | | | | | | | | | | | | | | | | | Warning about connecting to null object was printed when bearer plugin is missing when bearer management feature is enabled. Change-Id: Iac33081c5f301862c066eb69ec05ff6d95775c09 Reviewed-by: Markus Goetz (Woboq GmbH) <markus@woboq.com>
* | | Use Q_UNLIKELY for every qFatal()/qCritical()Marc Mutz2015-11-293-6/+6
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | If, after checking a condition, we issue a qFatal() or a qCritical(), by definition that check is unlikely to be true. Tell the compiler so it can move the error handling code out of the normal code path to increase the effective icache size. Moved conditional code around where possible so that we could always use Q_UNLIKELY, instead of having to revert to Q_LIKELY here and there. In some cases, simplified the expressions newly wrapped in Q_UNLIKELY as a drive-by. Change-Id: I67537d62b04bc6977d69254690c5ebbdf98bfd6d Reviewed-by: Konstantin Ritt <ritt.ks@gmail.com> Reviewed-by: Olivier Goffart (Woboq GmbH) <ogoffart@woboq.com>
* | | QHttpSocketEngine: remove unused membersAlex Trotsenko2015-11-262-6/+0
| | | | | | | | | | | | | | | | | | Change-Id: I136070100589993dcccf44666851c94d0fd30b1f Reviewed-by: Oswald Buddenhagen <oswald.buddenhagen@theqtcompany.com> Reviewed-by: Markus Goetz (Woboq GmbH) <markus@woboq.com>
* | | qsslsocket_shared_mac - fix a warning and compilation errorsTimur Pocheptsov2015-11-251-3/+3
| | | | | | | | | | | | | | | | | | | | | | | | SecTrustSettingsDomain is now (in the latest SDK) an enum, not a typedef for integer type. Change-Id: I1ad891190116cb27e10e38167fc15b4ee16a28f4 Reviewed-by: Eskil Abrahamsen Blomfeldt <eskil.abrahamsen-blomfeldt@theqtcompany.com>
* | | QSslSocket: evaluate CAs in all keychain categoriesDaniel Molkentin2015-11-245-52/+160
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | This will make sure that certs in the domainUser (login), and domainAdmin (per machine) keychain are being picked up in systemCaCertificates() in addition to the (usually immutable) DomainSystem keychain. Also consider the trust settings on OS X: If a certificate is either fully trusted or trusted for the purpose of SSL, it will be accepted. [ChangeLog][Platform Specific Changes] OS X now accepts trusted certificates from the login and system keychains. Task-number: QTBUG-32898 Change-Id: Ia23083d5af74388eeee31ba07239735cbbe64368 Reviewed-by: Markus Goetz (Woboq GmbH) <markus@woboq.com>
* | | Remove legacy platform code in QSslSocket for OS X < 10.5Daniel Molkentin2015-11-242-61/+27
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | This avoids manual symbol lookups and makes the code more readable. Mark identical code. Also use smart pointers instead of manual memory management. Change-Id: I62820313dce87de6623cdc87b6e1361200ed7822 Reviewed-by: Markus Goetz (Woboq GmbH) <markus@woboq.com>
* | | Merge remote-tracking branch 'origin/5.6' into devLiang Qi2015-11-233-10/+32
|\| | | | | | | | | | | | | | | | | | | | | | | Conflicts: src/corelib/kernel/qcoreapplication.cpp src/corelib/thread/qthread_unix.cpp Change-Id: Ia08d613c3f0bd08cb6dc3e3a57257207dfd4a099
| * | Use standard error handling in qhostinfo_winrt.cppOliver Wolff2015-11-191-9/+19
| | | | | | | | | | | | | | | Change-Id: I83555bf9952c01c68fb270a7e1f88ac0ee6ed373 Reviewed-by: Andrew Knight <andrew.knight@intopalo.com>
| * | winrt: Set error if host cannot be found in QHostInfoAgent::fromNameOliver Wolff2015-11-191-1/+6
| | | | | | | | | | | | | | | | | | Task-number: QTBUG-49478 Change-Id: Iab745100621db51219a42d575020783f6e9f310a Reviewed-by: Andrew Knight <andrew.knight@intopalo.com>
| * | winrt: no assert when device is in airplane mode/has no internet connectionOliver Wolff2015-11-191-0/+3
| | | | | | | | | | | | | | | | | | Task-number: QTBUG-49478 Change-Id: I1b95ca736d454f82f84374554e6cdec2555d29de Reviewed-by: Andrew Knight <andrew.knight@intopalo.com>
| * | QNAM: clean the channel request data on server disconnectAlex Trotsenko2015-11-181-0/+4
| | | | | | | | | | | | | | | | | | | | | | | | | | | Otherwise, we have unexpected channel close initiated by reply destructor. Change-Id: I15ad076ff20546e78787e19155544a2e5f8047a1 Reviewed-by: Oswald Buddenhagen <oswald.buddenhagen@theqtcompany.com> Reviewed-by: Markus Goetz (Woboq GmbH) <markus@woboq.com>
* | | Remove remaining support for BlackberryLouai Al-Khanji2015-11-216-341/+0
| | | | | | | | | | | | | | | | | | | | | | | | | | | The platform is no longer supported or actively maintained, and is in the way for improvements to the Unix event dispatcher and QProcess implementations. Change-Id: I3935488ca12e2139ea5f46068d7665a453e20526 Reviewed-by: Lars Knoll <lars.knoll@theqtcompany.com>
* | | QAbstractSocket: simplify a check for data availabilityAlex Trotsenko2015-11-191-8/+1
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | We know that the QAbstractSocketPrivate::canReadNotification() slot is called by the engine's read notifier only when new data is available for reading, or when the socket has been closed. This allows us to remove additional checks for engine validity and data availability for unbuffered sockets. Change-Id: Ic278cf2214d418d8fe471ea24a765b8d5840b0a5 Reviewed-by: Oswald Buddenhagen <oswald.buddenhagen@theqtcompany.com> Reviewed-by: Thiago Macieira <thiago.macieira@intel.com>
* | | Merge remote-tracking branch 'origin/5.6' into devLiang Qi2015-11-185-168/+219
|\| | | | | | | | | | | | | | | | | | | | | | | | | | | | | Conflicts: src/corelib/io/qprocess.cpp src/corelib/io/qprocess_unix.cpp src/network/kernel/qnetworkinterface_winrt.cpp tools/configure/configureapp.cpp Change-Id: I47df00a01597d2e63b334b492b3b4221b29f58ea
| * | winrt: Fixed listening to tcp socketOliver Wolff2015-11-181-3/+7
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | For some reason add_ConnectionReceived has to be called on the Xaml thread now. Otherwise the callback function won't be called and thus listening on a TCP socket won't work at all. Task-number: QTBUG-49121 Change-Id: I11ce2f72b0c1d3bb20e9579de5a2ce5150ca966a Reviewed-by: Andrew Knight <andrew.knight@intopalo.com> Reviewed-by: Samuel Nevala <samuel.nevala@intopalo.com> Reviewed-by: Maurice Kalinowski <maurice.kalinowski@theqtcompany.com>
| * | winrt: Clean up QNativeSocketEngineOliver Wolff2015-11-121-110/+112
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | WinRT/Windows Phone "coding guidelines" are now used for the native socket engine as well. - Whenever an operation is expected to succeed Q_ASSERT_SUCCEEDED is used. - QWinRTFunctions::await is used for waiting for async operations - Improved error handling Change-Id: I6c8d64731da5c94b911a5190231c7c8f68d9c261 Reviewed-by: Andrew Knight <andrew.knight@intopalo.com>
| * | winrt: Also list current profile in QNetworkInterface::allInterfacesOliver Wolff2015-11-091-52/+94
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | GetConnectionProfiles does not list the current profile, so "allInterfaces" also has to use GetInternetConnectionProfile. Task-number: QTBUG-49121 Change-Id: I80a3ea1bfddfe502c84376ca90a7e1fe5d3020c3 Reviewed-by: Samuel Nevala <samuel.nevala@intopalo.com> Reviewed-by: Andrew Knight <andrew.knight@intopalo.com>
| * | QNativeSocketEngine: fix build in debug mode under UnixAlex Trotsenko2015-11-091-4/+7
| | | | | | | | | | | | | | | Change-Id: I197e4853cd3ddd7543bbdb12cecc19c0ed2c9ee2 Reviewed-by: Thiago Macieira <thiago.macieira@intel.com>
| * | Make UnknownAccessibility not block requestsLorn Potter2015-11-062-2/+3
| | | | | | | | | | | | | | | | | | | | | | | | This allows requests to proceed without needing bearer plugins. Task-number: QTBUG-49267 Change-Id: Ie5ce188ddefebd14d666bb5846e8f93ee2925ed1 Reviewed-by: Markus Goetz (Woboq GmbH) <markus@woboq.com>
* | | Fix for a native socket engine on WindowsTimur Pocheptsov2015-11-161-0/+7
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | nativeConnect calls WSAConnect, tests its return value and then in case of SOCKET_ERROR checks WSAGetLastError and calls getsockopt to extract SO_ERROR. While MSDN says that getsockopt should clear the error, it's not true and this error can later affect in some weird way the next WSAConnect attempt/or nativeConnect's logic. Found in tst_qtcpsocket::bindThenResolveHost failing in this scenario: QHostInfo has a list of invalid/valid addresses, and as a result test doing strange things in waitForConnected and failing (and sometimes passing). Task-number: QTBUG-49255 Change-Id: I71f771647f305d8ca327d25ac7382a2edab96d17 Reviewed-by: Richard J. Moore <rich@kde.org>
* | | Merge remote-tracking branch 'origin/5.6' into devLiang Qi2015-11-0411-32/+36
|\| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Conflicts: config.tests/unix/ptrsize.test configure src/corelib/global/qnamespace.h src/network/socket/qabstractsocket.cpp tests/auto/other/networkselftest/networkselftest.pro Change-Id: Ic78abb4a34f9068567cea876861d4220f5a07672
| * | Merge remote-tracking branch 'origin/5.5' into 5.6Liang Qi2015-11-041-2/+3
| |\| | | | | | | | | | | | | | | | | | | | | | | | | Conflicts: src/corelib/io/qstorageinfo_unix.cpp src/plugins/platforms/windows/qwindowsmousehandler.cpp src/widgets/styles/qwindowsvistastyle.cpp Change-Id: Ie1725933815891cc8c86258d4c0e8ed0ab386edf
| | * Check if the session is valid before connecting to itAndy Shaw2015-10-271-2/+3
| | | | | | | | | | | | | | | | | | | | | | | | | | | Since there are circumstances where the session is not yet created after start() is called then we should check if the session is valid before connecting to it. Change-Id: I94236f76e4be2433a8c96eb91ce2d4b4d42f2fd9 Reviewed-by: Richard J. Moore <rich@kde.org>
| * | Doc: replaced mentions of deprecated functionNico Vertriest2015-11-031-10/+9
| | | | | | | | | | | | | | | | | | | | | | | | | | | setDefaultCaCertificates() --> QSslConfiguration::defaultConfiguration().setCaCertificates() Task-number: QTBUG-49119 Change-Id: I0b53165fe658bb7e459ad7a5960210fc6c91b916 Reviewed-by: Venugopal Shivashankar <venugopal.shivashankar@digia.com>
| * | Compile-fix: add missing declaration in debug.Edward Welbourne2015-10-301-0/+4
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | QAbstractSocketPrivate::readFromSocket() had a qDebug() that references its q->... so it also needs its Q_Q() declaration. Only relevant when QABSTRACTSOCKET_DEBUG is enabled (which it normally isn't). Change-Id: Ib82fd032fb2c4143a0987b9162377d0d7e968e95 Reviewed-by: Thiago Macieira <thiago.macieira@intel.com>
| * | QtNetwork: convert some QDateTime::currentDateTime() to currentDateTimeUtc()Marc Mutz2015-10-274-5/+8
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | The latter is much faster as it doesn't have to deal with time zones. This change is safe, because the QDateTimes are only used for comparison with other QDateTimes, which, from a quick glance around, seem to be mostly, if not exclusively, in UTC. Comparsions work across time zones, but the comparison between UTC date-times is fastest. Credits to Milian Wolff, from whose QtWS15 talk this advice is taken. Change-Id: I6859d886d8dc8e0a52fbe394fbb7b93a87b4739a Reviewed-by: Milian Wolff <milian.wolff@kdab.com> Reviewed-by: Friedemann Kleint <Friedemann.Kleint@theqtcompany.com> Reviewed-by: Lars Knoll <lars.knoll@theqtcompany.com>
| * | QNetworkReplyHttpImpl: convert some QDateTime::currentDateTime() to ↵Marc Mutz2015-10-271-2/+2
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | currentDateTimeUtc() The latter is much faster as it doesn't have to deal with time zones. This change is safe, because the QDateTime is only used to compare against a copy of itself, adjusted by some seconds, which doen't care which TZ the date-time is in, to get a time_t, which is much faster done from a UTC time, and to calculate the seconds to expirationTime, which, from a quick glance around, seem to be mostly, if not exclusively, in UTC. secsTo() works across time zones, but the comparison between UTC date-times is fastest. Credits to Milian Wolff, from whose QtWS15 talk this advice is taken. Change-Id: I22aa5350b29493f01fb503ef5ec68a964ca95cf3 Reviewed-by: Lars Knoll <lars.knoll@theqtcompany.com>
| * | Merge "Merge remote-tracking branch 'origin/5.5' into 5.6" into refs/staging/5.6Liang Qi2015-10-263-5/+6
| |\ \