summaryrefslogtreecommitdiffstats
path: root/src
Commit message (Collapse)AuthorAgeFilesLines
* qstandardpaths_win.cpp: Fix GetCurrentProcessToken() for Win7v5.15.0-rc2Fredrik Orderud2020-05-071-1/+6
| | | | | | | | | | | | | The GetCurrentProcessToken() was made an inline function for Windows 8. Expand it to ensure builds work independent of WINVER and disable low integrity support for Windows 7. Fixes: QTBUG-83941 Task-number: QTBUG-83453 Change-Id: Ic989f16621cd80cbc70c6b62779afab8a12714df Reviewed-by: Fredrik Orderud <forderud@gmail.com> Reviewed-by: Volker Hilsheimer <volker.hilsheimer@qt.io> Reviewed-by: Thiago Macieira <thiago.macieira@intel.com>
* QCborValue: catch overflow in QByteArray when decoding chunked stringsThiago Macieira2020-05-071-1/+1
| | | | | | | | | | We checked against integer overflow, but not against overflowing the QByteArray size limit. That caused a std::bad_alloc to be thrown, which is bad when decoding unknown data. QCborStreamReader wasn't affected, since it doesn't merge chunks. Change-Id: I99ab0f318b1c43b89888fffd160c36f495fada87 Reviewed-by: Volker Hilsheimer <volker.hilsheimer@qt.io>
* Fix 32bit integer overflow in ICC parsingv5.15.0-rc1Allan Sandfeld Jensen2020-05-041-1/+2
| | | | | | Change-Id: I98c413374374a6143733860aa9bab1a957cd3b2d Reviewed-by: Thiago Macieira <thiago.macieira@intel.com> Reviewed-by: Marc Mutz <marc.mutz@kdab.com>
* QCborValue: check parsing of invalid URLThiago Macieira2020-04-301-3/+5
| | | | | | | | | QUrl will reject invalid URLs for us, so we don't get normalization. The original junk should be retrievable, of course. Change-Id: Ibdc95e9af7bd456a94ecfffd160610f5b2c8e1a2 Reviewed-by: Ulf Hermann <ulf.hermann@qt.io> Reviewed-by: Edward Welbourne <edward.welbourne@qt.io>
* QCborValue: add an extra check against producing invalid ISO datesThiago Macieira2020-04-301-4/+6
| | | | | | | | | By QCborValue design, we store the textual representation in ISO format, equivalent of CBOR tag 0, which isn't allowed to have negative years or beyond year 10000. Change-Id: Ibdc95e9af7bd456a94ecfffd16060ccff359c296 Reviewed-by: Ulf Hermann <ulf.hermann@qt.io>
* QCborValue: avoid signed integer oveflows when decoding time_tThiago Macieira2020-04-301-4/+19
| | | | | | | | | | | | QDateTime::fromSecsSinceEpoch() multiplies by 1000 but does not check for overflow. That means we must do so in QCborValue validation. We can't use mul_overflow<qint64> on 32-bit platforms, so we do a compare- and-branch there. For 64-bit platforms, we prefer to do the multiplication with checked overflow, as the common case is that it will not overflow and we'll need the multiplication anyway. Change-Id: Ibdc95e9af7bd456a94ecfffd16060cba6f1c86b8 Reviewed-by: Edward Welbourne <edward.welbourne@qt.io>
* Don't output a warning that can trigger before Qt has fully initializedAndy Shaw2020-04-301-2/+0
| | | | | | | | | | | If a warning is outputted before Qt has had a chance to initialize the logging rules then it will cause it to hang as it will be stuck trying to initialize but can't continue because it needs to output the warning which triggered during that initialization. Therefore the warning should not be outputted to avoid this from happening. Change-Id: I202752c377bf69def2f7fb76be71b78d00ad3fd5 Reviewed-by: Volker Hilsheimer <volker.hilsheimer@qt.io>
* macOS: Avoid modifying hash while iterating itTor Arne Vestbø2020-04-301-1/+4
| | | | | | | | | | QCocoaTouch sneakily updated the list of active touches in the destructor, causing problems when we switched from Q_FOREACH to ranged-for. Fixes: QTBUG-83876 Change-Id: If7ec9e9116b7eb581580b461ae12ad70c739906d Reviewed-by: Simon Hausmann <hausmann@gmail.com>
* Doc: Remove manual duplicate alias descriptionsPaul Wicking2020-04-282-34/+0
| | | | | | | | | | With the introduction of the \typealias command to QDoc, QDoc generates a standardized line for aliased types. This patch removes duplication caused by the change in QDoc. Change-Id: I1a01c378f85b0decb7c0400a3b21146f0898c6ec Reviewed-by: Topi Reiniö <topi.reinio@qt.io>
* Fix 32bit int overflowAllan Sandfeld Jensen2020-04-271-2/+5
| | | | | | | Do not continue if the conversion to 32bit int would cause an overflow. Change-Id: I8a198dce5962e7ebd248b9baa92aba8730bfd3b0 Reviewed-by: Edward Welbourne <edward.welbourne@qt.io>
* Fix 8bit image conversions with non-default bytes_per_lineAllan Sandfeld Jensen2020-04-271-11/+33
| | | | | | | | | Copy line by line when bytes per line doesn't match between input and output. Fixes: QTBUG-83777 Change-Id: I44ca75963df6188c1de76196d9c12fd8bb081688 Reviewed-by: Eirik Aavitsland <eirik.aavitsland@qt.io>
* Doc: add since for QWheelEvent::positionPaul Wicking2020-04-271-0/+1
| | | | | | Fixes: QTBUG-83779 Change-Id: Icd39c6e3b65e17a51d04ea3c0718f2957948aaa4 Reviewed-by: Nico Vertriest <nico.vertriest@qt.io>
* Merge remote-tracking branch 'origin/5.14' into 5.15.0Qt Forward Merge Bot2020-04-271-1/+10
|\ | | | | | | Change-Id: I889c639db2fe24d17d535a2c4f52d72ea32491f8
| * Doc: Describe updating fonts with substitutes5.14Leena Miettinen2020-04-241-1/+10
| | | | | | | | | | | | Fixes: QTBUG-82577 Change-Id: I40662240da69c0d93d0386172c10f375fbb5fefc Reviewed-by: Paul Wicking <paul.wicking@qt.io>
* | Don't warn when loading icons via the image loadersTor Arne Vestbø2020-04-261-2/+0
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | 9d5ae9f26c98 introduced a warning when a matching icon engine was not found for a given file suffix, under the assumption that all formats would go through icon engine plugins. Unfortunately QIcon itself falls back to a direct use of QPixmapIconEngine when no icon engine plugin is found, which would lead to the warning being emitted for built in formats such as PNG. Until this code can be moved properly into QPixmapIconEngine we'll remove it. Change-Id: I14d1d33a0f0c29e4b4604ef3b53c05cb8e02f867 Reviewed-by: Tor Arne Vestbø <tor.arne.vestbo@qt.io> Reviewed-by: Simon Hausmann <simon.hausmann@qt.io>
* | Cocoa: If the grabRect is null then add in a null image for the areaAndy Shaw2020-04-261-1/+10
| | | | | | | | | | | | | | | | | | | | | | If it is null then it has nothing to grab, so a null QImage and QRect is added to the lists so that there is still a representation in some form for that display. This additionally ensures that it does take up space for the display in the final image too. Fixes: QTBUG-63086 Change-Id: I6e80ecc1170642025f6930e2211017c114e25c16 Reviewed-by: Tor Arne Vestbø <tor.arne.vestbo@qt.io>
* | Fix data corruption regression in QJsonObject::erase()Eirik Aavitsland2020-04-231-4/+4
| | | | | | | | | | | | | | | | | | The internal removeAt(index) method was implemented as taking cbor indexes directly, in contrast to the other ...At(index) methods. Fixes: QTBUG-83695 Change-Id: I16597eb6db1cf71e1585c041caa81bf8f7a75303 Reviewed-by: Thiago Macieira <thiago.macieira@intel.com>
* | Doc: Fix compilation issue with QVERIFY2 exampleKai Koehne2020-04-231-1/+1
| | | | | | | | | | | | | | | | | | | | | | | | | | Fixes error C2124: divide or mod by zero when compiling the test code (enabled by 713cd83200f3c60eac5d389dfabc44be1446e2ac). Pick-to: 5.15 Change-Id: I2ae39426fc0012f79714ff3d6484d792cab4bd92 Reviewed-by: Edward Welbourne <edward.welbourne@qt.io>
* | note QFileDialog::setNameFilters() is not supported on AndroidAssam Boudjelthia2020-04-231-0/+6
| | | | | | | | | | | | Task-number: QTBUG-83089 Change-Id: I134917476548f9756a14975be6b1b20312a8ca40 Reviewed-by: Friedemann Kleint <Friedemann.Kleint@qt.io>
* | Merge 5.15 into 5.15.0Alexandru Croitor2020-04-238-55/+102
|\ \ | | | | | | | | | Change-Id: Ib5251a8cb59693f076da7f75b86bfb6767bdf958
| * | macOS: Don't optimize out aggressive backingstore flushes when single-bufferedTor Arne Vestbø2020-04-221-2/+4
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Comparing the layer contents to the backingstore surface doesn't make sense when we're single buffered since we're always using the same surface. And once Core Animation has picked up on the surface it's not enough to just keep drawing to it, we also need to tell Core Animation that the contents has changed. Change-Id: I517a0b7a3ba7e9d96033465c9bd5a192985643ac Fixes: QTBUG-81071 Reviewed-by: Timur Pocheptsov <timur.pocheptsov@qt.io>
| * | Documentation: Add examples for Q_NAMESPACE(_EXPORT)Friedemann Kleint2020-04-221-0/+16
| | | | | | | | | | | | | | | | | | | | | It is not obvious how to use them. Change-Id: I60fdfb95f4c29cbc310d149495ebb38964e5a9ac Reviewed-by: Paul Wicking <paul.wicking@qt.io>
| * | Merge "Merge remote-tracking branch 'origin/5.14' into 5.15"Liang Qi2020-04-222-0/+4
| |\ \
| | * | Merge remote-tracking branch 'origin/5.14' into 5.15Liang Qi2020-04-222-0/+4
| | |\| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | This reverts commit 3a6d8df5219653b043bd642668cee193f563ec84. That change is only for 5.14. Conflicts: src/plugins/platforms/wasm/qwasmeventtranslator.cpp src/plugins/platforms/wasm/qwasmintegration.cpp src/plugins/platforms/wasm/qwasmopenglcontext.cpp src/plugins/platforms/wasm/qwasmscreen.cpp Change-Id: Ib9151e199291fe6eb4151027b515393c05303d65
| * | | Standardise language about quoted text in date/time format stringsEdward Welbourne2020-04-221-14/+14
| | | | | | | | | | | | | | | | | | | | Change-Id: Iaaeff8cd28a23b878ca07d716e67d4bd9fbb8176 Reviewed-by: Paul Wicking <paul.wicking@qt.io>
| * | | Handle specified time-spec in date-time parsingAndrei Golubev2020-04-226-39/+68
| |/ / | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | When a date-time was parsed from a string, the result was equal (as a date-time) to the correct value, but had (at least in some cases) the wrong spec, where it should have had a spec reflecting the zone specifier parsed. The time-spec imposed for the benefit of QDateTimeEdit is now moved from QDateTimeParser to QDateTimeEditPrivate, which takes over responsibility for imposing it. QDateTimeParser assumes Qt::LocalTime in member functions (where applicable) and uses the time-spec parsed from the string when constructing the date-time. QDateTime::fromString() and QLocale::toDateTime() are updated to use the full QDateTime returned by QDateTimeParser. Fixes: QTBUG-83075 Done-With: Edward Welbourne <edward.welbourne@qt.io> Change-Id: I8b79add2c7fc13a200e1252d48dbfa70b36757bf Reviewed-by: Qt CI Bot <qt_ci_bot@qt-project.org> Reviewed-by: Edward Welbourne <edward.welbourne@qt.io>
* | | QCborValue: don't update internal states if decoding a string failedThiago Macieira2020-04-221-1/+1
| | | | | | | | | | | | | | | | | | Change-Id: Ibdc95e9af7bd456a94ecfffd16061db982ad3fa7 Reviewed-by: Ulf Hermann <ulf.hermann@qt.io> Reviewed-by: Edward Welbourne <edward.welbourne@qt.io>
* | | QCborValue: fix double-accounting of the usedData when decoding stringsThiago Macieira2020-04-221-2/+0
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | We can only update usedData at the end, after we've decoded all chunks. The update inside the lambda was double-accounting for the first chunk, which could lead to signed integer overflows in usedData. Not unit-testable since the usedData value is not visible in the API. Change-Id: Ibdc95e9af7bd456a94ecfffd16061cc955208859 Reviewed-by: Ulf Hermann <ulf.hermann@qt.io> Reviewed-by: Edward Welbourne <edward.welbourne@qt.io>
* | | Merge remote-tracking branch 'origin/5.14' into 5.15.0Liang Qi2020-04-221-0/+2
|\ \ \ | | |/ | |/| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | This reverts commit 3a6d8df5219653b043bd642668cee193f563ec84. That change is only for 5.14. Conflicts: src/plugins/platforms/wasm/qwasmeventtranslator.cpp src/plugins/platforms/wasm/qwasmintegration.cpp src/plugins/platforms/wasm/qwasmopenglcontext.cpp src/plugins/platforms/wasm/qwasmscreen.cpp Change-Id: I2d845c795a683e1542201cfb6fdd185fec2b17ab
| * | QAuthenticator: Reset the authentication challengeMårten Nordheim2020-04-211-0/+2
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Both Negotiate and NTLM are conditioned on the 'challenge' being empty when starting the authentication process. So let's reset it when we start the authentication process. Fixes: QTBUG-83370 Change-Id: I41af6d5bcfe3dd980ca2bedce10ceff4f61047ff Reviewed-by: Andy Shaw <andy.shaw@qt.io> Reviewed-by: Timur Pocheptsov <timur.pocheptsov@qt.io>
| * | Merge remote-tracking branch 'origin/5.14.2' into 5.14Qt Forward Merge Bot2020-04-215-21/+22
| |\ \ | | | | | | | | | | | | Change-Id: I11019c23d949af45f0be814ab894dee602fb1b1a
| | * | Revert "wasm: Specify event targets by CSS selectors; Support emsdk >= 1.39.5"v5.14.2Morten Johan Sørvig2020-03-274-21/+20
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | This reverts commit c6da278271a2a3627b7a9933776cbdffc5bd2f23. This was a 5.15-only change which should not go into 5.14 since it raises the minimum supported emsdk version. Task-number: QTBUG-83098 Change-Id: I9e15952803f9dfff89b5b4e9caeff5c03dabca27 Reviewed-by: Morten Johan Sørvig <morten.sorvig@qt.io>
| | * | widgets: Re-calculate focus frame style option after setting new geometryTor Arne Vestbø2020-03-241-0/+2
| | | | | | | | | | | | | | | | | | | | | | | | Fixes: QTBUG-83019 Change-Id: I75d3d93732cb0c5a5b7350f19f0227998bda4791 Reviewed-by: Friedemann Kleint <Friedemann.Kleint@qt.io>
* | | | Merge remote-tracking branch 'origin/5.15' into 5.15.0Qt Forward Merge Bot2020-04-2132-80/+398
|\ \ \ \ | | |_|/ | |/| | | | | | Change-Id: I9d9f9e0955144241fcee6148fc78c4501e2ffcea
| * | | Doc: Fix documentation warnings for Qt CoreTopi Reinio2020-04-213-4/+11
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | qsocketnotifier.h:113:69: error: cannot initialize return object of type 'Qt::HANDLE' (aka 'void *') with an lvalue of type 'const QSocketDescriptor::DescriptorType' (aka 'const int') qsortfilterproxymodel.cpp:2938: error: out-of-line definition of 'recursiveFilteringEnabledChanged' does not match any declaration in 'QSortFilterProxyModel' qline.cpp:376: (qdoc) warning: Cannot find 'QLineF::IntersectionType' specified with '\enum' in any header file Fixes: QTBUG-83676 Change-Id: I57b51f4ad15fdc50db88100ad5b1cb85ed394b7a Reviewed-by: Paul Wicking <paul.wicking@qt.io>
| * | | Merge "Merge remote-tracking branch 'origin/5.14' into 5.15"Qt Forward Merge Bot2020-04-204-2/+112
| |\ \ \
| | * | | Merge remote-tracking branch 'origin/5.14' into 5.15Qt Forward Merge Bot2020-04-204-2/+112
| | |\| | | | | | | | | | | | | | | | | Change-Id: I088f72543f5a964ae073f434b819b5fda4c549c8
| | | * | sqlite: Fix CVE-2020-11656Andy Shaw2020-04-202-1/+80
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | This was taken from d09f8c3621d5f7f8 and b64674919f673602 in SQLite, ref: https://www3.sqlite.org/cgi/src/info/d09f8c3621d5f7f8 https://www.sqlite.org/cgi/src/info/b64674919f673602 [ChangeLog][QtSQL][sqlite] Fixed CVE-2020-11656 Fixes: QTBUG-83652 Change-Id: I99bd59dc10b753ff19822c902dff1fc339d330a8 Reviewed-by: Volker Hilsheimer <volker.hilsheimer@qt.io>
| | | * | sqlite: Fix CVE-2020-11655Andy Shaw2020-04-202-0/+31
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | This was taken from 4a302b42c7bf5e11 in SQLite, ref: https://www3.sqlite.org/cgi/src/info/4a302b42c7bf5e11 [ChangeLog][QtSQL][sqlite] Fixed CVE-2020-11655 Task-number: QTBUG-83652 Change-Id: I5ead78d9ee63aa0f12f1c1014c79373728569f30 Reviewed-by: Volker Hilsheimer <volker.hilsheimer@qt.io>
| | | * | doc: AA_DisableSessionManager was added in 5.14Liang Qi2020-04-201-1/+1
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | This amends 404bee752c5058506900c23faa9d577a38b300f1. Fixes: QTBUG-83611 Change-Id: Ic3379a646b9c70fb23fd1f3f4bebed6e0b485664 Reviewed-by: Paul Wicking <paul.wicking@qt.io>
| * | | | Markdown writer: omit space after opening code block fenceShawn Rutledge2020-04-201-1/+1
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | The CommonMark spec shows that it's not necessary to have a space between the code fence and the language string: https://spec.commonmark.org/0.29/#example-112 This also avoids a needless trailing space after a code fence that does not include a language string. Change-Id: I2addd38a196045a7442150760b73269bfe4ffb22 Reviewed-by: Volker Hilsheimer <volker.hilsheimer@qt.io>
| * | | | Markdown writer: don't wrap code block, and detect its endShawn Rutledge2020-04-201-7/+10
| |/ / / | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | The end of a code block nested in a list item is now detected; and if the text of the list item continues after the code block, it continues to be indented. Code blocks should never be word-wrapped. Fixes: QTBUG-80603 Change-Id: I4427f8b1d4807d819616f5cb971e2d006170d9be Reviewed-by: Volker Hilsheimer <volker.hilsheimer@qt.io>
| * | | Merge "Merge remote-tracking branch 'origin/5.14' into 5.15"Liang Qi2020-04-202-1/+3
| |\ \ \
| | * | | Merge remote-tracking branch 'origin/5.14' into 5.15Liang Qi2020-04-202-1/+3
| | |\| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Conflicts: mkspecs/features/qt_common.prf src/network/ssl/qsslsocket_openssl_symbols.cpp src/network/ssl/qsslsocket_openssl11_symbols_p.h src/network/ssl/qsslsocket_opensslpre11_symbols_p.h src/plugins/platforms/wasm/qwasmeventdispatcher.cpp Done-With: Timur Pocheptsov <timur.pocheptsov@qt.io> Change-Id: I04fb3139a0e2efd4bc2f0959f131679f192fa0f8
| | | * | OpenSSL: handle SSL_shutdown's errors properlyTimur Pocheptsov2020-04-166-7/+36
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Do not call SSL_shutdown on a session that is in handshake state (SSL_in_init(s) returns 1). Also, do not call SSL_shutdown if a session encountered a fatal error (SSL_ERROR_SYSCALL or SSL_ERROR_SSL was found before). If SSL_shutdown was unsuccessful (returned code != 1), we have to clear the error(s) it queued. Unfortunately, SSL_in_init was a macro in OpenSSL 1.0.x. We have to resolve SSL_state to implement SSL_in_init. Fixes: QTBUG-83450 Change-Id: I6326119f4e79605429263045ac20605c30dccca3 Reviewed-by: Mårten Nordheim <marten.nordheim@qt.io> (cherry picked from commit 8907635da59c2ae0e8db01f27b24a841b830e655)
| | | * | wasm: do not try to resume main thread if mainloop has not started yetLorn Potter2020-04-141-1/+2
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | (cherry picked from commit d928beb024c240b37d35d2c53f25648c99a484b4) Fixes: QTBUG-83293 Change-Id: Ibd891629d1d023e47d196dd60821cc5c583a178d Reviewed-by: Morten Johan Sørvig <morten.sorvig@qt.io>
| | | * | Add information for macOS to qsystemdetection.hLars Schmertmann2020-04-141-0/+2
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Change-Id: Ibc99b5481709b1b99cdbbdd94ad544175871cbae Reviewed-by: Alex Blasche <alexander.blasche@qt.io> Reviewed-by: Thiago Macieira <thiago.macieira@intel.com>
| * | | | Add support for high resolution wheel events from Linux 5.0+Allan Sandfeld Jensen2020-04-202-2/+36
| |/ / / | | | | | | | | | | | | | | | | | | | | | | | | | | | | They come in as a different relative axis, and we need to ignore the old axis to not scroll double. Change-Id: I808cce95417ec9f8058dee26d0a2694dda27944d Reviewed-by: Gatis Paeglis <gatis.paeglis@qt.io>
| * | | QSocketNotifier::activated(QSocketDescriptor...) doc fixupMårten Nordheim2020-04-171-0/+4
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | We agreed to make the type internal but somehow it slipped my mind to actually label them as such. Task-number: QTBUG-70441 Change-Id: Id90521ecc09bfa1db29601b96ba70bcdcb64d458 Reviewed-by: Thiago Macieira <thiago.macieira@intel.com>
| * | | rcc: Always seed the hash with 0hjk2020-04-171-5/+4
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | That was already done to pass the auto tests, but the randomization also bites for reproducible builds. Change-Id: Ibf4da513059deb5a806d2ac1a83c1994edf09d4a Reviewed-by: Thiago Macieira <thiago.macieira@intel.com>