summaryrefslogtreecommitdiffstats
path: root/tests/auto/dbus
Commit message (Collapse)AuthorAgeFilesLines
* Merge remote-tracking branch 'origin/5.6' into devLiang Qi2016-02-021-1/+1
|\ | | | | | | | | | | | | | | | | Conflicts: config.tests/unix/compile.test src/plugins/platforms/cocoa/qcocoahelpers.mm src/tools/qlalr/cppgenerator.cpp Change-Id: I0103ca076a9aca7118b2fd99f0fdaf81055998c3
| * Autotest: rename the test class so it's different in this testThiago Macieira2016-01-301-1/+1
| | | | | | | | | | | | Change-Id: I3d11545be52c43119f0fffff142b0e5e91b1e878 Reviewed-by: Oswald Buddenhagen <oswald.buddenhagen@theqtcompany.com> Reviewed-by: Thiago Macieira <thiago.macieira@intel.com>
* | Add Intel copyright to files that Intel has had non-trivial contributionThiago Macieira2016-01-218-0/+8
| | | | | | | | | | | | | | | | | | I wrote a script to help find the files, but I reviewed the contributions manually to be sure I wasn't claiming copyright for search & replace, adding Q_DECL_NOTHROW or adding "We mean it" headers. Change-Id: I7a9e11d7b64a4cc78e24ffff142b506368fc8842 Reviewed-by: Lars Knoll <lars.knoll@theqtcompany.com>
* | Updated license headersJani Heikkinen2016-01-2129-496/+351
| | | | | | | | | | | | | | | | | | | | | | | | | | From Qt 5.7 -> tools & applications are lisenced under GPL v3 with some exceptions, see http://blog.qt.io/blog/2016/01/13/new-agreement-with-the-kde-free-qt-foundation/ Updated license headers to use new GPL-EXCEPT header instead of LGPL21 one (in those files which will be under GPL 3 with exceptions) Change-Id: I42a473ddc97101492a60b9287d90979d9eb35ae1 Reviewed-by: Thiago Macieira <thiago.macieira@intel.com> Reviewed-by: Lars Knoll <lars.knoll@theqtcompany.com>
* | Merge remote-tracking branch 'origin/5.6' into devSimon Hausmann2016-01-121-7/+0
|\| | | | | | | Change-Id: I5839bded07e23af65ced9491c4f50242f964dd31
| * Revert "dbus: Add method serial() and replySerial() to class DBusMessage."Thiago Macieira2016-01-111-7/+0
| | | | | | | | | | | | | | | | | | This reverts commit 618e2cc081e09d9222418bd933876224675a7530. The original commit has a section of code that I failed to review properly and is of questionable functionality. Change-Id: I61c53d7b8b2aa7c3312292b017a18aba7da11bc5 Reviewed-by: Thiago Macieira <thiago.macieira@intel.com>
* | Merge remote-tracking branch 'origin/5.6' into devFrederik Gladhorn2016-01-0811-6/+144
|\| | | | | | | | | | | Based on merge done by Liang Qi Change-Id: Id566e5b9f284d29bff2199f13f9417c660f5b26f
| * dbus: Add method serial() and replySerial() to class DBusMessage.Ralf Habacker2016-01-071-0/+7
| | | | | | | | | | | | | | | | | | | | | | | | | | This patch includes setup of class member 'msg' in QDBusMessagePrivate::toDBusMessage() to be able to get the serial after message sending. Testcases for comparing the 'reply serial to' with the 'serial' are included. Task-number: QTBUG-44490 Change-Id: Iae7c48f5b0c70a6c5ae500904072b38b46dfd876 Reviewed-by: Thiago Macieira <thiago.macieira@intel.com>
| * Autotest: Make sure that we can place calls with disabled deliveryThiago Macieira2016-01-031-2/+4
| | | | | | | | | | | | | | | | This often happens in applications. Besides, we are expecting at least a call to RequestName to happen. Change-Id: Ifd2454ffba454fd591d0ffff1425a84563267d19 Reviewed-by: David Faure <david.faure@kdab.com>
| * Autotest: test both libdbus-1 load failure and connection failureThiago Macieira2016-01-023-1/+9
| | | | | | | | | | Change-Id: I39cc61d0d59846ab8c23ffff14242294649c1a45 Reviewed-by: Lorn Potter <lorn.potter@gmail.com>
| * Autotest: Mark D-Bus tests that don't connect to the bus as parallelThiago Macieira2016-01-025-5/+5
| | | | | | | | | | | | | | There's no problem running them in parallel. Change-Id: I39cc61d0d59846ab8c23ffff142420a127ab6968 Reviewed-by: Lorn Potter <lorn.potter@gmail.com>
| * Suspend processing of some messages in the default busses by defaultThiago Macieira2016-01-023-0/+121
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | To retain a bit compatibility with applications developed in the last 9 years that expect that QDBusConnections won't process their events until the event loop runs, we now suspend the handling of incoming messages in the two default buses (and only in them) and resume when the event loop starts. This is required because the new threaded QtDBus would otherwise process incoming messages that the application didn't expect it to. For example, if the application first acquires names on the bus and only after that registers objects with QtDBus, there's a small window in which the name is acquired and visible to other applications, but no objects are registered yet. Calls to those objects may be received, would then be processed in the QDBusConnectionManager thread and fail. The work around is to disable the actual handling of method calls and signals in QDBusConnectionPrivate::handleMessage. Instead, those messages are queued until later. Due to the way that libdbus-1 works, outgoing method calls that are waiting for replies are not affected, since their processing does not happen in handleMessage(). [ChangeLog][Important Behavior Changes] QtDBus now uses threads to implement processing of incoming and outgoing messages. This solves a number of thread safety issues and fixes an architectural problem that would cause all processing to stop if a particular thread (usually the main thread) were blocked in any operation. On the flip side, application developers need to know that modifications to a QDBusConnection may be visible immediately on the connection, so they should be done in an order that won't allow for incomplete states to be observed (for example, first register all objects, then acquire service names). Change-Id: I39cc61d0d59846ab8c23ffff1423c6d555f6ee0a Reviewed-by: David Faure <david.faure@kdab.com>
* | Tests: Remove empty init/cleanup slots, constructors and destructors.Friedemann Kleint2015-12-101-5/+0
| | | | | | | | | | | | | | | | Move some code (like registrations of meta types) from init() to initTestCase() in the process. Change-Id: I57db5156647cfadab554fbed853b2e68b2815f3b Reviewed-by: Frederik Gladhorn <frederik.gladhorn@theqtcompany.com>
* | Merge remote-tracking branch 'origin/5.6' into devLiang Qi2015-10-141-1/+5
|\| | | | | | | | | | | | | | | | | Conflicts: tests/auto/corelib/io/qfile/tst_qfile.cpp tests/auto/corelib/io/qprocess/tst_qprocess.cpp tests/auto/corelib/tools/qversionnumber/qversionnumber.pro Change-Id: Ia93ce500349d96a2fbf0b4a37b73f088cc505c6e
| * Tests: Always verify whether QTemporaryDir/File creation succeeded.Friedemann Kleint2015-09-281-1/+5
| | | | | | | | | | | | | | | | | | | | | | Use QVERIFY2() with QTemporaryDir/File::errorString() consistently. Attempt to catch issues like the below warning and follow-up issues. QSYSTEM: tst_QFiledialog::clearLineEdit() QFileSystemWatcher: FindNextChangeNotification failed for "C:\Users\qt\_____aaaaaaaaaaaaaaaaaaaaaa" (Access is denied.) Task-number: QTBUG-47370 Change-Id: I58a6e87c502627e976efa62ad73c912f3b2d49fa Reviewed-by: Jędrzej Nowacki <jedrzej.nowacki@theqtcompany.com>
* | Tests: Fix single-character string literals.Friedemann Kleint2015-10-131-2/+2
| | | | | | | | | | | | | | Use character literals where applicable. Change-Id: I1a026c320079ee5ca6f70be835d5a541deee2dd1 Reviewed-by: Simon Hausmann <simon.hausmann@theqtcompany.com>
* | Merge remote-tracking branch 'origin/5.6' into devLiang Qi2015-09-2511-298/+503
|\| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Conflicts: src/corelib/io/io.pri src/corelib/io/qdatastream.cpp src/corelib/io/qdatastream.h src/network/socket/qabstractsocket.cpp src/plugins/platforminputcontexts/ibus/qibusplatforminputcontext.cpp src/plugins/platforms/cocoa/qcocoaaccessibilityelement.h src/widgets/styles/qgtkstyle.cpp tests/auto/corelib/mimetypes/qmimedatabase/qmimedatabase-cache/qmimedatabase-cache.pro tests/auto/corelib/mimetypes/qmimedatabase/qmimedatabase-xml/qmimedatabase-xml.pro tests/auto/dbus/qdbusconnection/qdbusconnection.pro tests/auto/dbus/qdbuspendingcall/tst_qdbuspendingcall.cpp tests/auto/network/access/qnetworkreply/tst_qnetworkreply.cpp Change-Id: I347549a024eb5bfa986699e0a11f96cc55c797a7
| * tst_QDBusAbstractInterface: fix racy test failing every so oftenThiago Macieira2015-09-241-2/+8
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | The explanation is in the code comment. Ever since QDBusConnections began being processed in a separate thread, we were relying on the fact that the main thread didn't begin processing its event queue until the second event got posted (the event loop only exits after it has finished processing all pending events). We had a race between the main thread starting its processing, at which point it decides which is the last event it will process, and the QDBusConnectionManager thread posting the second event. This is very fragile code, since it depends on the behavior of QDBusConnectionPrivate (how it stores the signal relays in a hash) and that of QHash with duplicate keys. This only works because the hash key between the two connections is the same (it's only dependent on the method name and interface name). If we ever begin using something that isn't the same between "control" and "p", then with QHash's randomness, we'll be racy again. Change-Id: I42e7ef1a481840699a8dffff1406c3a4674ec3a6 Reviewed-by: Alex Blasche <alexander.blasche@theqtcompany.com>
| * Add getter and setter for qt_qhash_seedGabriel de Dietrich2015-09-221-6/+1
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | In some cases it's not possible to use QT_HASH_SEED, specially when we need to set the environment variable from inside the application, as dynamically loaded libraries or plugins may create static QHash instances. That would set qt_qhash_seed to a value different from -1 and skip the env var value. For those cases, and when we still want to set qt_qhash_seed, we provide a way to enforce its value. Auto-tests accessing qt_qhash_seed directly have been updated accordingly. Usage in qdoc, uic and rcc has been left as is for the time being. Change-Id: I3b35b4fa0223c83b1348a6508641905a2a63266f Reviewed-by: Lars Knoll <lars.knoll@theqtcompany.com>
| * tst_QDBusAbstractAdaptor: fix reception of signals from P2P connectionThiago Macieira2015-09-151-1/+1
| | | | | | | | | | | | | | | | | | | | | | | | | | P2P connections don't have senders and receivers, so asking QDBusConnection to connect to a signal with a sender was a mistake (added in 5368e44a86a4e0d4582ff5268986ea8bd0fa64ca). Due to an internal bug, this never presented itself -- double fault. Fix the connection so that we don't get unit test failures when the bug is solved. Change-Id: I9a75ad8521ae4e5cbbe5ffff13d1a78b7dea6d07 Reviewed-by: Alex Blasche <alexander.blasche@theqtcompany.com>
| * QDBusServiceWatcher: Move the logic to QDBusConnectionPrivateThiago Macieira2015-09-151-0/+104
| | | | | | | | | | | | | | | | | | | | | | With kdbus, we won't have a regular signal, but instead a special message. So keep the logic of what to do in QDBusConnectionPrivate. The #ifdef is to make sure the bootstrapped qdbuscpp2xml continues to build in cross-compilation environments. Change-Id: Iee8cbc07c4434ce9b560ffff13d06f0d9904cb6d Reviewed-by: Alex Blasche <alexander.blasche@theqtcompany.com>
| * And move the creation of connections to the threadThiago Macieira2015-09-156-257/+378
| | | | | | | | | | | | | | | | | | | | Now we know that all timers and socket notifiers get created only in the QDBusConnectionManager thread. Incidentally, this reduced code duplication. Change-Id: I27eaacb532114dd188c4ffff13d5075a8d2efb0b Reviewed-by: Alex Blasche <alexander.blasche@theqtcompany.com>
| * Use a dedicated thread for handling incoming libdbus-1 eventsThiago Macieira2015-09-151-32/+1
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Each application will have one thread dedicated for this, for all QDBusConnections. I wouldn't mind sharing such a thread with other uses in Qt, provided none of them ever block (the QProcessManager thread comes to mind, but it's going away soon). The cost associated with this change in this commit is so far rather minimal. All incoming D-Bus calls need to be handled after an event is posted anyway, to avoid deadlocking on reentering libdbus-1 functions that acquire locks still held. The cost is the one more thread running and the cost of synchronizing them when an event is posted. The benefits far outweigh that cost: no longer will we have problems of QtDBus failing to run if the main system or session connections are used before QCoreApplication is run. Moreover, events can be received and handled in aux threads even if the main thread is blocked on some operation. Note: this commit may not be testable (tst_qdbusconnection may fail) Task-number: QTBUG-43585 Change-Id: Ic5d393bfd36e48a193fcffff13b737556ccd11a8 Reviewed-by: Albert Astals Cid <aacid@kde.org> Reviewed-by: Alex Blasche <alexander.blasche@theqtcompany.com>
| * Implement the blocking QtDBus call in terms of the non-blocking oneThiago Macieira2015-09-151-2/+12
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | This simplifies the code a little by having a single code path. More importantly, we no longer need to call the evil function dbus_connection_send_with_reply_and_block. That function acquires a lock on the socket transport inside libdbus-1, which means all threads need to wait until the one call gets unblocked before they can continue. To do that, this commit reimplements the QDBus::Block part of QDBusConnectionPrivate::sendWithReply by reusing the existing call to sendWithReplyAsync() and then doing a blocking-wait with QDBusPendingCallPrivate::waitForFinished(). By using (Q)DBusPendingCall and the threaded connection approach (next commit), now we never block on the socket. That also means the code to call dbus_pending_call_block() is no longer necessary and the waitForFinished() function itself can be considerably simplified. As a side-effect of no longer blocking, a number of pre-existing race conditions that used to be hidden showed up. Note: this commit deadlocks without the threading (next commits). Task-number: QTBUG-43585 Change-Id: Ic5d393bfd36e48a193fcffff13b73754954a3f7d Reviewed-by: Albert Astals Cid <aacid@kde.org> Reviewed-by: Alex Blasche <alexander.blasche@theqtcompany.com>
* | Remove QT_DISABLE_DEPRECATED_BEFORE=0 from tests not using deprecated API.Friedemann Kleint2015-09-0121-21/+0
| | | | | | | | | | Change-Id: I1955320e7639760b4383a53f37a506c8055933ef Reviewed-by: Liang Qi <liang.qi@theqtcompany.com>
* | tests/auto/dbus: Replace Q[TRY]_VERIFY(a == b) by Q[TRY]_COMPARE(a, b).Friedemann Kleint2015-08-195-40/+40
|/ | | | | | | | | | | | - Replace Q[TRY]_VERIFY(pointer == 0) by Q[TRY]_VERIFY(!pointer). - Replace Q[TRY]_VERIFY(smartPointer == 0) by Q[TRY]_VERIFY(smartPointer.isNull()). - Replace Q[TRY]_VERIFY(a == b) by Q[TRY]_COMPARE(a, b) and add casts where necessary. The values will then be logged should a test fail. Change-Id: I363776ef664c97bca0071d57cf78a8fe935bce8e Reviewed-by: Thiago Macieira <thiago.macieira@intel.com>
* Don't try to dynamically resolve dbus symbols if QT_NO_LIBRARYUlf Hermann2015-08-132-1/+5
| | | | | Change-Id: I9e307653229c04746d66d3a9f3b3e46ea9a42381 Reviewed-by: Thiago Macieira <thiago.macieira@intel.com>
* Merge remote-tracking branch 'origin/5.5' into devFrederik Gladhorn2015-08-068-4/+4
|\ | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Conflicts: doc/global/qt-cpp-defines.qdocconf src/3rdparty/forkfd/forkfd.c src/corelib/codecs/qtextcodec.cpp src/corelib/kernel/qmetatype.cpp src/corelib/tools/qset.qdoc src/gui/accessible/qaccessible.cpp src/gui/image/qpixmapcache.cpp src/opengl/qgl.cpp src/tools/qdoc/generator.cpp src/widgets/kernel/qwidget.cpp tests/auto/widgets/widgets/qcombobox/tst_qcombobox.cpp Change-Id: I4fbe1fa756a54c6843aa75f4ef70a1069ba7b085
| * Autotest: rename sub tests from "test" to something meaningfulThiago Macieira2015-07-188-4/+4
| | | | | | | | | | | | | | | | | | Otherwise, if I open tests/auto/dbus/dbus.pro in Qt Creator, it shows me "test", "test2", "test3", "test4" and it's very hard to know which test is which. Change-Id: Iee8cbc07c4434ce9b560ffff13d0654696c025b7 Reviewed-by: Frederik Gladhorn <frederik.gladhorn@theqtcompany.com>
* | Extend flakeyness of tst_QDBusAbstractAdaptor::overloadedSignalEmission(int)Simon Hausmann2015-06-201-1/+1
| | | | | | | | | | | | | | | | This isn't specific to an Ubuntu version, unfortunately. It also fails on OpenSuSE occasionally and other Ubuntu versions. Change-Id: I6a1ca55a198270f1a1e8a9916e9f768762211550 Reviewed-by: Lars Knoll <lars.knoll@theqtcompany.com>
* | Blacklist and skip various tests that are flakeySimon Hausmann2015-06-142-0/+5
| | | | | | | | | | | | | | | | | | | | They didn't show up in the "old" CI runs because they usually pass the second time they are executed - which the testrunner does. The new CI doesn't do that anymore, instead we now mark those tests explicitly and will track their record of passing and failing in the new metrics database. Change-Id: Id34dd6f792f38995b07b6fec88f833df64de2f8b Reviewed-by: Lars Knoll <lars.knoll@digia.com>
* | Merge remote-tracking branch 'origin/5.5' into devSimon Hausmann2015-06-032-10/+36
|\| | | | | | | | | | | | | | | | | | | | | | | | | | | | | Conflicts: src/corelib/global/qnamespace.qdoc src/corelib/io/qwindowspipereader.cpp src/corelib/io/qwindowspipereader_p.h src/corelib/statemachine/qstatemachine.cpp src/corelib/statemachine/qstatemachine_p.h src/plugins/platforms/xcb/qxcbconnection.h tests/auto/network/access/qnetworkreply/tst_qnetworkreply.cpp tests/auto/tools/qmake/tst_qmake.cpp tests/manual/touch/main.cpp Change-Id: I917d694890e79ee3da7d65134b5b085e23e0dd62
| * Make sure we don't call dbus_connection_can_send_type on too old libdbusThiago Macieira2015-05-261-9/+24
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | This function was introduced alongside the support for Unix file descriptors, so it's a good indicator of whether Unix FDs are supported. Ever since dbus_minimal_p.h, however, DBUS_TYPE_UNIX_FD may be defined even if the system libs don't support it. In order to fix this issue, I had to fix what was apparently a merge conflict resolution mistake and remove the #ifdef around the test. Doing the latter is a good idea due to moc being unable to find <dbus/dbus.h>. This was tested with both linked and dynamically-loaded libdbus-1. Task-number: QTBUG-46199 Change-Id: I66a35ce5f88941f29aa6ffff13dfb4b5438613a3 Reviewed-by: Jani Vähäkangas <jani.vahakangas@theqtcompany.com> Reviewed-by: Alex Blasche <alexander.blasche@theqtcompany.com>
| * Merge remote-tracking branch 'origin/5.4' into merge5.5Allan Sandfeld Jensen2015-05-081-1/+12
| |\ | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Conflicts: src/corelib/global/qglobal.h src/corelib/io/qnoncontiguousbytedevice_p.h src/gui/image/qjpeghandler.cpp src/network/access/qhttpthreaddelegate_p.h tests/auto/corelib/io/qlockfile/tst_qlockfile.cpp tests/auto/widgets/widgets/qmenubar/BLACKLIST Change-Id: I01de8c1c28efcedfd7953d05025f54802dc08ab3
| | * Autotest: Check if this D-Bus library knows about file descriptorsThiago Macieira2015-05-081-1/+12
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Because if it doesn't, then calling dbus_type_is_fixed or is_basic may result in a failed assertion. process 16304: arguments to dbus_type_is_fixed() were incorrect, assertion "_dbus_type_is_valid (typecode) || typecode == DBUS_TYPE_INVALID" failed in file dbus-signature.c line 345. Change-Id: Idf715b895bac4d56b4afffff13db2ed71b1516a5 Reviewed-by: Allan Sandfeld Jensen <allan.jensen@theqtcompany.com>
* | | Merge remote-tracking branch 'origin/5.5' into devLiang Qi2015-04-0114-27/+0
|\| | | | | | | | | | | | | | | | | | | | | | | Conflicts: src/testlib/qtestblacklist.cpp src/widgets/accessible/qaccessiblewidgets.cpp Change-Id: If032adb9296428f62384ed835dbf41ee7a0b886c
| * | Tests: remove insignificant flag for dbus tests on osxCaroline Chao2015-03-2714-27/+0
| | | | | | | | | | | | | | | | | | | | | | | | | | | Tests are now passing in CI. Change-Id: I0051fb7070c1c1027c557eba9dde6367ad59ac7a Task-number: QTQAINFRA-837 Reviewed-by: Frederik Gladhorn <frederik.gladhorn@theqtcompany.com> Reviewed-by: Thiago Macieira <thiago.macieira@intel.com>
* | | Autotest: fix incorrect test message ignoringThiago Macieira2015-03-311-4/+4
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Commit 748abf9347c03743d0c50b6b4d94765154158dac changed the message, but the CI either did not run the QtDBus tests when integrating or it ignored the results. Task-number: QTBUG-45317 Change-Id: Iee8cbc07c4434ce9b560ffff13d058f21b73ac05 Reviewed-by: Liang Qi <liang.qi@theqtcompany.com> Reviewed-by: Alberto Mardegan <mardy@users.sourceforge.net>
* | | Add QDBusMessage::createTargetedSignal()Alberto Mardegan2015-03-141-0/+45
|/ / | | | | | | | | | | | | | | | | | | | | | | | | | | | | The QDBusMessage::createSignal() static method doesn't take a parameter for specifying the destination service of the signal. While this is not a widely used feature, it can be useful to avoid waking up all connected clients when the service knows what are the clients which are interested in the signal. This commit adds a QDBusMessage::createTargetedSignal() method which also takes the destination service as its first parameter. Change-Id: I9fdca53673a6944c39c93c1efd69a9d02859684e Task-number: QTBUG-44704 Reviewed-by: Thiago Macieira <thiago.macieira@intel.com>
* | QDBusConnection::registorObject with interfaceKevron Rees2015-02-151-0/+70
| | | | | | | | | | | | | | | | | | | | | | | | Currently QDBus relies on a key in QMetaClassInfo to understand the DBus interface name. This patch allows QDBus to also use a specified interface name in the registerObject call instead of relying on QMetaClassInfo that might not be there (if the QObject was created in QML or Javascript for example). Change-Id: Ie02b2c67e7deb07f43e35eb166c11833fcbf38f3 Task-number: QTBUG-44074 Reviewed-by: Kevron Rees <kevron.m.rees@intel.com> Reviewed-by: Thiago Macieira <thiago.macieira@intel.com>
* | Update copyright headersJani Heikkinen2015-02-1126-182/+182
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Qt copyrights are now in The Qt Company, so we could update the source code headers accordingly. In the same go we should also fix the links to point to qt.io. Outdated header.LGPL removed (use header.LGPL21 instead) Old header.LGPL3 renamed to header.LGPL3-COMM to match actual licensing combination. New header.LGPL-COMM taken in the use file which were using old header.LGPL3 (src/plugins/platforms/android/extract.cpp) Added new header.LGPL3 containing Commercial + LGPLv3 + GPLv2 license combination Change-Id: I6f49b819a8a20cc4f88b794a8f6726d975e8ffbe Reviewed-by: Matti Paaso <matti.paaso@theqtcompany.com>
* | Merge remote-tracking branch 'origin/5.4' into devFrederik Gladhorn2015-01-2113-82/+172
|\| | | | | | | | | | | | | | | | | | | | | | | | | | | | | Conflicts: src/corelib/global/global.pri src/corelib/global/qcompilerdetection.h src/corelib/global/qglobal.h src/corelib/tools/qdatetime.cpp src/plugins/platforms/xcb/qxcbscreen.h src/plugins/platforms/xcb/qxcbwindow.h src/widgets/dialogs/qcolordialog.cpp src/widgets/dialogs/qcolordialog_p.h tools/configure/configureapp.cpp Change-Id: Ie9d6e9df13e570da0a90a67745a0d05f46c532af
| * Fix compilation with older MSVC: use qIsNan instead of isnanThiago Macieira2015-01-151-2/+2
| | | | | | | | | | | | | | | | | | isnan is C99 and POSIX.1, which the older MSVC do not support. Use the Qt equivalent. Change-Id: Ic5d393bfd36e48a193fcffff13b8679cb83d12db Reviewed-by: Alex Blasche <alexander.blasche@theqtcompany.com> Reviewed-by: Friedemann Kleint <Friedemann.Kleint@theqtcompany.com>
| * Fix memory leaks with QDBusServerThiago Macieira2015-01-111-0/+2
| | | | | | | | | | | | | | | | | | | | | | | | | | Two serious mistakes: - we need to call dbus_server_free_data_slot as many times as we call dbus_server_allocate_data_slot - we need to delete the d pointer... The changes to the unit tests are simply to cause the used peer connections to be removed so they don't show up in valgrind. Change-Id: I9fd1ada5503db9ba481806c09116874ee81f450d Reviewed-by: Alex Blasche <alexander.blasche@theqtcompany.com>
| * Make QtDBus unit tests compile with runtime dbus-1 tooThiago Macieira2015-01-064-44/+76
| | | | | | | | | | | | | | | | | | | | | | | | | | There's a change in Qt 5.4.0 that makes Qt compile with its own set of D-Bus headers, which means QT_CFLAGS_DBUS may be empty. Thus, we can't compile or link if we're using the actual libdbus-1 API to build the test. This commit makes these unit tests use the same dynamic loading mechanism. Change-Id: I56b2a7320086ef88793f6552cb54ca6224010451 Reviewed-by: Simon Hausmann <simon.hausmann@digia.com>
| * Make QDBusConnection and QDBusServer return an error on default objectsThiago Macieira2015-01-061-4/+4
| | | | | | | | | | | | | | | | | | | | The error of "Not connected". This incidentally solves a crash when QDBusServer().lastError() is called but libdbus-1 couldn't be found. Change-Id: Id93f447d00c0aa6660d4528c4bbce5998d9186a8 Reviewed-by: Alex Blasche <alexander.blasche@theqtcompany.com>
| * Autotest: fix a race condition in verifying a peer D-Bus connectedThiago Macieira2015-01-066-14/+52
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | On the unit test side, everything is sequential: we first ask for the connection, verify that it is connected, then ask the remote side via the session bus if it is connected. Unfortunately, the remote site may handle things in a different order: it may handle the incoming function call to "isConnected" before doing accept(2) on the listening socket. So, instead, make the local side block until the connection is received on the other side. On the remote, we don't block, instead we use the feature of delayed replies. Change-Id: Ie386938b8b39dd94a9d7e5913668125fb4a3c7da Reviewed-by: Alex Blasche <alexander.blasche@theqtcompany.com>
| * Autotest: Forward stderr of the sub-processesThiago Macieira2015-01-025-1/+4
| | | | | | | | | | | | | | So we can get the output when running with QDBUS_DEBUG=1. Change-Id: I6a6b8e0d82727c522914fb90a7ce594c86307d8f Reviewed-by: Frederik Gladhorn <frederik.gladhorn@theqtcompany.com>
| * Autotest: Be nicer when asking the sub-processes to exitThiago Macieira2015-01-028-17/+32
| | | | | | | | | | | | | | | | | | | | Instead of killing them outright (and note that terminate() doesn't work on Windows), ask them nicely to exit on their own. This way, if we run them in valgrind, valgrind gets a chance to print the leak check output and summary. Change-Id: Ib6cc8d4560ff0bf255f94980eb220e97592c00f0 Reviewed-by: Frederik Gladhorn <frederik.gladhorn@theqtcompany.com>
* | Remove the old QDBusConnection::sender functionalityThiago Macieira2015-01-061-11/+5
| | | | | | | | | | | | | | | | | | | | | | | | | | This has been deprecated since QDBusContext was introduced (Qt 4.3). So it's time to remove the functionality. [ChangeLog][Important Behavior Change] QDBusConnection::sender() (deprecated since Qt 4.3) has changed to always return an invalid QDBusConnection. To know what connection the incoming call was received from, use QDBusContext. Change-Id: I355efb82c14e54ed718c8f892d8267e727b19118 Reviewed-by: Alex Blasche <alexander.blasche@theqtcompany.com>