summaryrefslogtreecommitdiffstats
Commit message (Collapse)AuthorAgeFilesLines
* QVLA: do not include QtTest5.15Giuseppe D'Angelo12 hours1-1/+1
| | | | | | | | | The right include is QTest, QtTest drags in all of QtCore. Change-Id: Icc2964ccdb85fe1bfc9fe8f43351a4605a34329b Reviewed-by: Volker Hilsheimer <volker.hilsheimer@qt.io> (cherry picked from commit bfe77a21fb0988a52fb77af09fe9675eb151e8b6) Reviewed-by: Qt Cherry-pick Bot <cherrypick_bot@qt-project.org>
* Doc: Fix documentation of qmake's exists() functionJoerg Bornemann30 hours1-2/+3
| | | | | | | | | | This function may take a wildcard expression, not a general regular expression. Change-Id: Ia7ba3bac47c310bc035620583b9d2102fdc5ffb0 Reviewed-by: Leena Miettinen <riitta-leena.miettinen@qt.io> (cherry picked from commit 116c2115f84ec2f5f12b5d7680cd83ceeef72a6e) Reviewed-by: Qt Cherry-pick Bot <cherrypick_bot@qt-project.org>
* Limit value in setFontWeightFromValue()Robert Loehning36 hours1-1/+1
| | | | | | | | | Fixes: oss-fuzz-24986 Change-Id: Ic65139a7821be3a12c65444d010736f03c8b74f5 Reviewed-by: Edward Welbourne <edward.welbourne@qt.io> (cherry picked from commit ccc205bf38ffbe60180a069939a4aff01e7734e5) Reviewed-by: Jonas Karlsson <jonas.karlsson@qt.io> Reviewed-by: Volker Hilsheimer <volker.hilsheimer@qt.io>
* QStackedLayout: fix a memory leakGiuseppe D'Angelo2 days1-1/+3
| | | | | | | | | A layout takes ownership of the QLayoutItem passed to addItem. Change-Id: Iea3c64453f3cbf4f1b5660e505c1a35dca537833 Reviewed-by: Volker Hilsheimer <volker.hilsheimer@qt.io> (cherry picked from commit 1fcc882d7ca564f17e49b8d51adc43eb5b97c57b) Reviewed-by: Qt Cherry-pick Bot <cherrypick_bot@qt-project.org>
* QPasswordDigestor - improve code coverageTimur Pocheptsov2 days1-0/+59
| | | | | | | | | | By extending (a bit) an auto-test to cover paths found by LCOV. All of them is just to trigger the code that checks input parameters. Change-Id: I62f9a9045038ff8d123fd1396f4bfd85e75c6d8f Reviewed-by: Mårten Nordheim <marten.nordheim@qt.io> (cherry picked from commit 95cbce3e6e0d8a1e82260cfb5b78491a3906be86) Reviewed-by: Qt Cherry-pick Bot <cherrypick_bot@qt-project.org>
* Avoid integer overflow and division by zeroAllan Sandfeld Jensen2 days1-3/+3
| | | | | | | | | | | | Restrain patterns to sensible lengths and values. [ChangeLog][QCosmeticStroker] Pen patterns are restrained to a maximum length and values of 1024, fixing oss-fuzz issue 25310. Change-Id: If062f8336ff5ad113258391b0d70b8ac6f42c4b3 Reviewed-by: Robert Loehning <robert.loehning@qt.io> Reviewed-by: Eirik Aavitsland <eirik.aavitsland@qt.io> (cherry picked from commit 1ff25785ff93d0bd3d597e3a65a261bdbfa13c3b)
* wasm: fix resizing of qwidget windowsLorn Potter3 days2-1/+36
| | | | | | | | | | This also fixes the cursor changing during resize mode Fixes: QTBUG-85361 Change-Id: Ic85a5c31a8a2dc4265a84f16fd5fcdc231062c6d Reviewed-by: Morten Johan Sørvig <morten.sorvig@qt.io> (cherry picked from commit 0de0a6a54c496b5c3c8d79647924476837a02354) Reviewed-by: Qt Cherry-pick Bot <cherrypick_bot@qt-project.org>
* QMutex: Work around ICC bug in dealing with constexpr constructorThiago Macieira3 days1-1/+1
| | | | | | | | | | | | | | The bug report says it also happens in some MSVC builds, but no one has so far been able to reproduce it or give us a log with more details, so not working around the issue for MSVC. ICC, howevere, is known to have a lot of parsing issues, so I'm not surprised and don't feel a problem working around them. This fix is not applicable for Qt 6. Fixes: QTBUG-85644 Change-Id: If51855da004b4f3fbf43fffd1649b64e05cb91cc Reviewed-by: Allan Sandfeld Jensen <allan.jensen@qt.io>
* Fix x-height name in stylesheet docsFlorian Bruhin5 days1-1/+1
| | | | | | | | | | | | The *height* of an x being called "ex width" makes no sense. Also, it seems like this measurement is typically called "x-height" rather than "ex height", see e.g. https://en.wikipedia.org/wiki/X-height Change-Id: Id8e2c1aa9be1a4a60e667a076486777d34f1e76d Reviewed-by: Paul Wicking <paul.wicking@qt.io> (cherry picked from commit befa3729db0d1010694bd1bb4cbadd36ff5c49fb) Reviewed-by: Fabian Kosmale <fabian.kosmale@qt.io>
* Android: Fix android accessibility not being set activeVikke Matikainen5 days3-1/+17
| | | | | | | | | | | | | | | Android platform event of activating accessibility might be received, before the platform plugin is initialized, thus disregarding the activation step. This change saves the activation event state and defers setting it in platform integration. Fixes: QTBUG-77320 Change-Id: I06aab76159d1de0e72c0c535dbe80c2858f8e79b Reviewed-by: Volker Hilsheimer <volker.hilsheimer@qt.io> (cherry picked from commit b1433a6988d79c162ab5bed116be1ffeedca2ea9) Reviewed-by: Qt Cherry-pick Bot <cherrypick_bot@qt-project.org>
* Fix QSFPM not emitting dataChanged when source model is setWang ChunLin5 days3-0/+32
| | | | | | | | | | | | | | | QSortFilterProxyModel did not emit dataChanged when calling setSourceModel() after modifying the source model. QSortFilterProxyModel::setSourceModel and QSortFilterProxyModelPrivate::_q_sourceReset(), _q_clearMapping is called to delete the source_index_mapping. They also need to call create_mapping function to re-create it. Fixes: QTBUG-87781 Change-Id: Idbe34696c9d3a2fbf354b653c870bac61378811d Reviewed-by: Volker Hilsheimer <volker.hilsheimer@qt.io> (cherry picked from commit 8455bfee76ed3f1bd3bba8bd3688a7afa94ae0bb) Reviewed-by: Qt Cherry-pick Bot <cherrypick_bot@qt-project.org>
* QCoreApplication: add more information to processEvents() docsThiago Macieira5 days1-0/+3
| | | | | | | | | | Just shows how bad an idea to call this function it is. Fixes: QTBUG-88653 Change-Id: If51855da004b4f3fbf43fffd1648fc294065160d Reviewed-by: Lars Knoll <lars.knoll@qt.io> (cherry picked from commit 8ec9a48e80a72c7b9e82107a2c66de6cbf7a02fe) Reviewed-by: Qt Cherry-pick Bot <cherrypick_bot@qt-project.org>
* Be more consistent when converting JSON values from variantSona Kurazyan5 days6-100/+139
| | | | | | | | | | | | | | | | | | | When converting from numeric QVariant types to QJsonValue, we always convert to double. However, when converting from QVariantMap or QVariantList, we convert to qint64, which may result to negative number in the corner cases. Fixed to always cast to double, which matches with the pre-5.15.0 behavior. Note, that in Qt 6 QJsonValue got native support for integers, and we consistently fallback to double only if the value is outside the range of qint64, so this fix applies only to 5.15. [ChangeLog][Important Behavior Changes] Restored pre-5.15.0 behavior when converting from numeric QVariant values to QJson* types. Such values now always convert to a double QJsonValue. Fixes: QTBUG-88168 Change-Id: I584a35aa6ffade22a1c83fcda5598ed912f53919 Reviewed-by: Thiago Macieira <thiago.macieira@intel.com> Reviewed-by: Qt CI Bot <qt_ci_bot@qt-project.org>
* Fix logic error in QString::replace(ch, after, cs)Andreas Buhr5 days2-1/+12
| | | | | | | | | | | Coverage analysis showed that an if-branch marked "Q_LIKELY" was never taken. It turns out the code was incorrect, but behaved correctly. This patch fixes the logic and adds a unit test. Change-Id: I9b4ba76392b52f07b8e21188496e23f98dba95a9 Reviewed-by: Thiago Macieira <thiago.macieira@intel.com> (cherry picked from commit ebaae45ea17efc230209ed90d94596647cf6cb48) Reviewed-by: Sona Kurazyan <sona.kurazyan@qt.io>
* macOS: Upgrade supported SDK to 11.0Tor Arne Vestbø5 days1-1/+1
| | | | | | | | | | | | Testing seems to indicate building against the 11.0 SDK works fine, and doesn't opt in to any new behaviors on Big Sur that Qt isn't ready for. Change-Id: I7da11cf25f2be7443c94ba7a4e9cd99dc1034455 Reviewed-by: Alexandru Croitor <alexandru.croitor@qt.io> Reviewed-by: Timur Pocheptsov <timur.pocheptsov@qt.io> (cherry picked from commit a07c9a1a70ce755140dd31f55c6acd72270f4ddd) Reviewed-by: Qt Cherry-pick Bot <cherrypick_bot@qt-project.org>
* Doc: explain how to create a test touch device for use with touchEventMitch Curtis5 days1-1/+7
| | | | | | | Change-Id: Ib60eb0754449da7c50f8632ebd5228ddbe8389f1 Reviewed-by: Volker Hilsheimer <volker.hilsheimer@qt.io> (cherry picked from commit 5861e06568c44c58aecacdf26fd7938240348956) Reviewed-by: Qt Cherry-pick Bot <cherrypick_bot@qt-project.org>
* tst_qocsp: improve code coverageTimur Pocheptsov5 days1-3/+16
| | | | | | | | | | By simply extending the basic test to trigger qHash, isEqual and a bunch of getters. Change-Id: Ib1d88fc6d2ad623743cea77ac286ae6ac819dfd1 Reviewed-by: Timur Pocheptsov <timur.pocheptsov@qt.io> (cherry picked from commit 1d7189f5b3eb03e7c71fb31e2bd491d0e5a535e4) Reviewed-by: Qt Cherry-pick Bot <cherrypick_bot@qt-project.org>
* macOS: Propagate device-pixel-ratio of system tray iconTor Arne Vestbø5 days1-0/+1
| | | | | | | | | | | | | | | | | When preparing a system tray icon on a system with a retina screen, we end up creating a full-height icon of height 44. If there's also a 1x screen available, macOS will scale down this image for us when presenting the icon on the 1 screen, but the downscale will fail to preserve the aspect ratio of the original image on Big Sur. Telling macOS which device-pixel-ratio the image has seems to fix this, and is the right thing to do in any case. Fixes: QTBUG-88600 Change-Id: Ic31def94d073da1b256bbfcaf5905f92c169f43d Reviewed-by: Alexandru Croitor <alexandru.croitor@qt.io> (cherry picked from commit a6aaa2b7071b7666a807b450dc5738742f3cc9e0) Reviewed-by: Qt Cherry-pick Bot <cherrypick_bot@qt-project.org>
* QDtls - remove redundant RAII structTimur Pocheptsov5 days1-13/+1
| | | | | | | | | | | | As noted by LCOV, the part with q_BIO_free(bio) was never executed since we were taking the result from QScopedPointer before returning. While it's a what RAII idiom is for, there is quite a low probability that SSL_set_bio() one day will start throwing exceptions. Change-Id: Id24e480dac34166c627b71bb2972de558c644339 Reviewed-by: Timur Pocheptsov <timur.pocheptsov@qt.io> (cherry picked from commit 16f4ce89eda53645a412b73e0c5ea63e638e7268) Reviewed-by: Qt Cherry-pick Bot <cherrypick_bot@qt-project.org>
* widgets: Don't report new focus object during clearFocus() unless neededTor Arne Vestbø5 days1-6/+7
| | | | | | | | | | | | | | | We do not unconditionally clear focus_child like the existing comment said. We only do it if the focus_child was the widget that is clearing focus. So in many cases we'll end up with the same focus object as before. We can not report that as a focusObjectChanged to the window, as that will potentially trigger a reset or cancel of the current input method for the (unchanged) focus object. Fixes: QTBUG-86976 Change-Id: I54367e46eda7a94d967f58960bd926c195dc09cc Reviewed-by: Volker Hilsheimer <volker.hilsheimer@qt.io> (cherry picked from commit 7d5ba1c17ecbb620731ff7322fd278c3ce496dad) Reviewed-by: Qt Cherry-pick Bot <cherrypick_bot@qt-project.org>
* Ensure that QMenu is polished before setting the screen in popup()David Redondo5 days1-1/+2
| | | | | | | | | | | | | | | Some styles alter the widget that will influence the underlying platform window. An example is when a style would want to draw the menu with some transparency and sets the Qt::WA_TranslucentBackground attribute. This needs to happen before the platform window is created. However calling QWidgetPrivate::setScreen will end up creating the window and the surface format will be fixed at this point. Change-Id: I707cf1de5c1614382cffbea1aae8cdb01f7de44a Reviewed-by: Nate Graham Reviewed-by: Richard Moe Gustavsen <richard.gustavsen@qt.io> (cherry picked from commit 36b1d37cef09769eea22f78d77440ac4c5d008d8) Reviewed-by: Qt Cherry-pick Bot <cherrypick_bot@qt-project.org>
* Doc: Fix documentation warnings in Qt NetworkTopi Reinio6 days3-6/+13
| | | | | | | Change-Id: I3653977a4511aa5c296a3954399342d98ac71586 Reviewed-by: Paul Wicking <paul.wicking@qt.io> (cherry picked from commit 49e8d0f3d5836e0fc1577ace1f0a3677d0e309b7) Reviewed-by: Qt Cherry-pick Bot <cherrypick_bot@qt-project.org>
* Doc: Fix documentation warnings for Qt XMLTopi Reinio6 days1-28/+12
| | | | | | | | | | Content for the deprecated SAX interface was removed, remove rest of the linking as well. Change-Id: Idd233a821139837b779e551aeba914114500e39e Reviewed-by: Paul Wicking <paul.wicking@qt.io> (cherry picked from commit 0ac7a81250e7291d12d9a176197260344884419c) Reviewed-by: Qt Cherry-pick Bot <cherrypick_bot@qt-project.org>
* Doc: Document QGradient::Preset enum valuesTopi Reinio6 days1-1/+170
| | | | | | | | | Fixes: QTBUG-85749 Change-Id: Ie77145e851ff64d4c88fce7211135d66e9b94a84 Reviewed-by: Tor Arne Vestbø <tor.arne.vestbo@qt.io> Reviewed-by: Paul Wicking <paul.wicking@qt.io> (cherry picked from commit fddb0c895f9a12d61bbc4cf33149a8d1a93eaf19) Reviewed-by: Qt Cherry-pick Bot <cherrypick_bot@qt-project.org>
* Use QTRY_COMPARE in an attempt to make the test less flakyVolker Hilsheimer6 days1-2/+2
| | | | | | | | | | The test function only runs on X11, and this might help with the asynchronous nature of the client/server architecture, also for drag'n'drop. Change-Id: I38db9104e304e57c36f84932d13f8dfae7452883 Reviewed-by: Shawn Rutledge <shawn.rutledge@qt.io> (cherry picked from commit ee025760cf7040d2864327c9bd478f7d0792a79f)
* QSocks5SocketEngine: Fix out-of-bounds access of QBAMårten Nordheim7 days1-3/+1
| | | | | | | | | | This should've been caught a long time ago, but long story short: it wasn't. This has been deprecated since 5.14 and is now asserting. Change-Id: Iddee22b1a68e5d1a03006831f795db8ec1c472be Reviewed-by: Giuseppe D'Angelo <giuseppe.dangelo@kdab.com> (cherry picked from commit 456699da93323ca3ad56ca8f16aa3197dec380e6) Reviewed-by: Qt Cherry-pick Bot <cherrypick_bot@qt-project.org>
* Fuzzing: Add a test for QDateTime::fromStringEdward Welbourne7 days2-0/+110
| | | | | | | | | | | This patch adds a basic fuzzing test for QDateTime::fromString. Task-number: QTBUG-87104 Change-Id: Icc51386f06f6d4d2a4495734f7fa45de80c6e065 Reviewed-by: Robert Loehning <robert.loehning@qt.io> (cherry picked from commit 28e4a8421ca618097bf8de35dab17ffbd423e468) Reviewed-by: Qt Cherry-pick Bot <cherrypick_bot@qt-project.org>
* HTTP2: fix crash from assertionMårten Nordheim7 days2-2/+7
| | | | | | | | | | | | | | | | In general the protocolHandler isn't deleted unless the channel is being destructed. So instead of reset()ing the pointer we keep it around. Also update the http2protocolhandler to mimic the http1 handler a little closer: shutting down the channel in receiveReply if there's no reply/activeStreams, and not calling receiveReply at all if there's no activeStreams. Change-Id: I702547f594deb6b0c1384068f7e93e560527e8e2 Reviewed-by: Timur Pocheptsov <timur.pocheptsov@qt.io> (cherry picked from commit 0b21c15b11e9af64741e26822f33dfba5975d9b0) Reviewed-by: Qt Cherry-pick Bot <cherrypick_bot@qt-project.org>
* Link to qAlpha in qRgb() and qRgba() docsMitch Curtis7 days1-2/+2
| | | | | | | Change-Id: I5a3b8573123e82f4c8c92fa7a2e1af06e2e84eb2 Reviewed-by: Venugopal Shivashankar <Venugopal.Shivashankar@qt.io> (cherry picked from commit 418389c3ed925b2da3538d808ceeb53727978a8c) Reviewed-by: Qt Cherry-pick Bot <cherrypick_bot@qt-project.org>
* Fix shaping problems on iOS 14 / macOS 11Eskil Abrahamsen Blomfeldt7 days2-2/+2
| | | | | | | | | | | | | | | | | | | | | | | | | | | | Detection of AAT fonts was exclusively based on the existence of tables mort, morx and kerx. In the SF font (the UI default) on iOS 14 and Big Sur, none of these tables actually exist, so we would accidentally use the OpenType shaper for it. But there are plenty of other AAT tables in the font and the OT shaper can´t handle it. In particular, this caused us to get the wrong advance for comma when it was followed by a space. Looking at all the affected SF fonts on Big Sur, they all have the trak table, so we expand the detection to include this. This is possibly also the table used to determine the correct glyph positions in this case. In Qt 6, this already works as expected, because Harfbuzz has built-in support for AAT and does not require the CoreText fallback. Therefore, this is just a hotfix for the 5.15 series and there is no need to upstream this patch. [ChangeLog][macOS] Fixed shaping of default UI font on macOS 11 and iOS 14. Fixes: QTBUG-88495 Change-Id: Ia2b3f45cbc0c32b93864760cb427ede6b0566e8f Reviewed-by: Tor Arne Vestbø <tor.arne.vestbo@qt.io> Reviewed-by: Lars Knoll <lars.knoll@qt.io>
* macOS: Account for Big Sur always enabling layer backed viewsTor Arne Vestbø7 days1-2/+9
| | | | | | | | | | | | | | | | | | | Previous versions of macOS (Mojave and Catalina) enabled layer backing only when the application's build SDK was 10.14 or above, to provide an opt-out workaround for applications that were not ready for layer backing. This seems to no longer be the case, as Big Sur will enable layer backing regardless of the SDK version used. Tested by passing -Wl,-sdk_version -Wl,10.13 -v -mlinker-version=519 during linking, to simulate what the effects of linking to the 10.13 would be. Also confirmed by real-world use of the 10.13 SDK via Xcode 9. Change-Id: I867edc001b6709ba0ad0fd70918bd9b77d317cf8 Fixes: QTBUG-87014 Pick-to: 5.12 Reviewed-by: Alexandru Croitor <alexandru.croitor@qt.io> Reviewed-by: Timur Pocheptsov <timur.pocheptsov@qt.io>
* [Android] Ensure windows always have a geometry on creationPiotr Mikolajczyk7 days2-9/+11
| | | | | | | | | | | | | | | | A QWindow created without an explicit geometry needs to pick up a default geometry in the platform plugin. If the window has a maximized of fullscreen window state, it will fill the entire available geometry of the parent window (or the screen if there's not parent window). Fixes: QTBUG-69159 Fixes: QTBUG-69156 Fixes: QTBUG-69154 Change-Id: If8565d92a97bb4b3fa44757e68969d54d0bc7ebe Reviewed-by: Tor Arne Vestbø <tor.arne.vestbo@qt.io> (cherry picked from commit f92e1953699b2529cc6ea2fd399fe4f2b887e83c) Reviewed-by: Assam Boudjelthia <assam.boudjelthia@qt.io>
* Bump versionLiang Qi8 days1-1/+1
| | | | | | Change-Id: I5697edf968dfaebe25c73899d26ed234631e55dc Reviewed-by: Kevin Funk <kevin.funk@kdab.com> Reviewed-by: Jani Heikkinen <jani.heikkinen@qt.io>
* Fix QGraphicsItem crash if click right button of mouseZhang Yu8 days1-2/+6
| | | | | | | | | | | In this case, the 'parent' is QGraphicsTextItem which isn't a object inheriting from QWidget. Converting QGraphicsTextItem to QWidget by static_cast and using it as QWidget leads to crash. Fixes: QTBUG-88309 Change-Id: I3c583f43125eb36841848434d1fa9a135b0e9f57 Reviewed-by: Volker Hilsheimer <volker.hilsheimer@qt.io> (cherry picked from commit 4df5f93018344f6cdc6cd5a08a084b1c61e0c076)
* Fix misidentification of some shearing QTransforms as only rotatingEirik Aavitsland10 days2-3/+4
| | | | | | | | | The dot product used rows instead of columns. Fixes: QTBUG-87984 Change-Id: I922f67ed0fa9a4f88aa4e9fc6d3c09f8dda21688 Reviewed-by: Lars Knoll <lars.knoll@qt.io> (cherry picked from commit 7aa68ee6f2e08ce0b4f5c698a8c012895f738dd2)
* Android: Treat ACTION_CANCEL as TouchPointReleasedBartlomiej Moskal12 days1-1/+1
| | | | | | | | | | | | | | | | | | | | | | | | | | | | If TouchPointPressed was previously send and there is no TouchPointReleased, we are exposed to uncorrectly handled touches by application. Some Android devices can recognize hand gestures. In some case the gesture may be handled by Android System. In this situation ACTION_CANCEL MotionEvent is delivered ACTION_CANCEL - from Android specification: -"Occurs when the parent takes possession of the motion, for example when the user has dragged enough across a list view that it will start scrolling instead of letting you press the buttons inside of it" -"The current gesture has been aborted. You will not receive any more points in it. You should treat this as an up event, but not perform any action that you normally would" If ACTION_CANCEL appears it means that ACTION_UP will not be delivered to application. That is why ACTION_CANCEL need to be treat as TouchPointReleased event. Fixes: QTBUG-72110 Change-Id: I8f32930cdb424b7530adc87b8334ac48a3bb9d57 Reviewed-by: Assam Boudjelthia <assam.boudjelthia@qt.io> (cherry picked from commit 64d62c53c1e92a1cc07449a0ea3c71501592c1e7) Reviewed-by: Bartlomiej Moskal <bartlomiej.moskal@siili.com>
* QCharRef: properly disable assignment from charGiuseppe D'Angelo12 days1-0/+4
| | | | | | | | | | | | | | | Under QT_NO_CAST_FROM_ASCII the assignment would fall back to operator=(int) after a promotion. Add a deleted overload to block this. (QChar itself uses a private constructor for the same purpose, but I chose the C++11 solution). Nothing to do in Qt 6, QCharRef is gone. Change-Id: Iba50ad2b6ad95d7c3a5e4920ab03fae5d3db0319 Fixes: QTBUG-88431 Reviewed-by: Volker Hilsheimer <volker.hilsheimer@qt.io> Reviewed-by: Albert Astals Cid <aacid@kde.org> Reviewed-by: Lars Knoll <lars.knoll@qt.io>
* Android: fix android java and templates targets with -developer-buildAssam Boudjelthia12 days2-5/+15
| | | | | | | | | | | | | | | On Windows with -developer-build java and templates files are not copied properly, this makes sure to copy the files and dir for both targets. Also, avoid creating a a deployment-settings.json file by adding "TEMPLATE = aux". Fixes: QTBUG-87627 Change-Id: Iae269c3180a7b6d904fdba2e69fb3f815bbb1211 Reviewed-by: Andy Shaw <andy.shaw@qt.io> Reviewed-by: Alexandru Croitor <alexandru.croitor@qt.io> (cherry picked from commit 73e64a98c696f516aed204cf79bacce7d2179030) Reviewed-by: Qt Cherry-pick Bot <cherrypick_bot@qt-project.org>
* Android: recommend against using ANDROID_ABIS inside the project fileAssam Boudjelthia13 days1-7/+3
| | | | | | | | Task-number: QTCREATORBUG-24674 Change-Id: Iad6baa1af61d3d1a44f26cb9d51e3cb97d235707 Reviewed-by: Joerg Bornemann <joerg.bornemann@qt.io> (cherry picked from commit 0d6a14bbd992977b5ba07ba4134b1ad68dc4656a) Reviewed-by: Qt Cherry-pick Bot <cherrypick_bot@qt-project.org>
* Android: Add the required linker flags for unwinding on armeabi-v7aAndy Shaw14 days1-0/+3
| | | | | | | | | | These flags are indicated as required for armeabi-v7a here: https://android.googlesource.com/platform/ndk/+/master/docs/BuildSystemMaintainers.md#Unwinding Change-Id: Id2bbfc65c4ed9bda29692869a719dbab70891491 Reviewed-by: Assam Boudjelthia <assam.boudjelthia@qt.io> (cherry picked from commit 85fe4c89835d862db30b43c775d8863fcf896f20) Reviewed-by: Qt Cherry-pick Bot <cherrypick_bot@qt-project.org>
* Android: Add the QtAndroidBearer.jar to the jar dependenciesAndy Shaw14 days1-1/+1
| | | | | | | | | This amends 8f088c9f82f7db089f62add74e1fe2ac8da55cd3 to ensure that both the QtAndroidNetwork.jar and QtAndroidBearer.jar are included as dependencies for the network module on Android. Change-Id: If5b53ee5efeafe17abc854a6c266c3aeab1dd649 Reviewed-by: Assam Boudjelthia <assam.boudjelthia@qt.io>
* QMutex: order reads from QMutexPrivate::waiters and QBasicMutex::d_ptr in ↵Alexander Kartashov14 days1-1/+1
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | QBasicMutex::lockInternal() Threads that unlock and lock a mutex at the same time perform the following operations: Thread 1 Thread 2 -------- -------- QBasicMutex::lockInternal() QBasicMutex::unlockInternal() d_ptr.testAndSetOrdered(..., d) d = d_ptr.loadAcquire() d->waiters.loadRelaxed(); (1) d->waiters.fetchAndAddRelease() (2) d_ptr.testAndSetRelease(d, 0) (3) d->derefWaiters() (4) d->waiters.testAndSetRelaxed(...) (5) if (d != d_ptr.loadAcquire()) (6) d->wait() The operation (1) isn't serialized with the operation (6) so its memory effect may be observed before the effect of the operation (1). However, if memory effects are observed in the following order: (6) -> (1) -> (2) -> (3) -> (4) -> (5) then Thread 1 doesn't notice that Thread 2 updates d_ptr and goes to sleep with d pointing to a stale object, this object isn't reachable since d_ptr is zeroed so Thread 1 cannot be woken up. The patch adds the "acquire" barrier into the operation (1) so that it cannot be reordered with the operation (6). Fixes: QTBUG-88247 Change-Id: I1d0c405c0bf5080ec1815d351b9b4b75efeab21a Reviewed-by: Olivier Goffart (Woboq GmbH) <ogoffart@woboq.com> Reviewed-by: Thiago Macieira <thiago.macieira@intel.com> (cherry picked from commit d08e3b6de16118becaada17a58aed4042f400a5a) Reviewed-by: Qt Cherry-pick Bot <cherrypick_bot@qt-project.org>
* Android: Don't use putIfAbsent as that is not available in older APIsAndy Shaw2020-11-111-2/+2
| | | | | | | Fixes: QTBUG-88076 Change-Id: I1ab12c574be036babfd0e4aacb44d1f75c66f4ad Reviewed-by: Assam Boudjelthia <assam.boudjelthia@qt.io> (cherry picked from commit 2b4a581f34854d9c0bb8d53626d929abd0661bd8)
* QAsn1Element: Read value in blocks to avoid oom at wrong lengthRobert Loehning2020-11-111-5/+13
| | | | | | | | | Fixes oss-fuzz issue 22272. Change-Id: I8a49b9487f632469402c983e517e817e8e65bef7 Reviewed-by: Allan Sandfeld Jensen <allan.jensen@qt.io> (cherry picked from commit ad9ca01853e90bdbe45f7ac2e8edd75cd0862801) Reviewed-by: Qt Cherry-pick Bot <cherrypick_bot@qt-project.org>
* Q_PRIMITIVE_TYPE: improve the documentationGiuseppe D'Angelo2020-11-101-2/+3
| | | | | | | | | | | | | | A key piece of information missing from Q_PRIMITIVE_TYPE documentation is that for them value initialization must equal memset()ting with zeroes. A type like QPoint is primitive because `QPoint p;` is initialized to (0, 0), but a type like QSize is movable (and NOT primitive) because `QSize s;` is actually initialized to (-1, -1). Amend the docs. Change-Id: I121684810da46be5d0579c7d3de945149390a32a Reviewed-by: Lars Knoll <lars.knoll@qt.io> (cherry picked from commit b8b75cdcfa71189c7726607be7b66d0ddeaae372) Reviewed-by: Volker Hilsheimer <volker.hilsheimer@qt.io>
* Fix pcre2 feature conditionsJoerg Bornemann2020-11-101-2/+2
| | | | | | | | | | | The pcre2 feature was turned off when the user passed -system-pcre to configure. The reason were faulty expressions in the enable/disable fields. Fixes: QTBUG-88295 Change-Id: I4edee49a9c797797ef3b80f955b48b5492fb4fc7 Reviewed-by: Alexandru Croitor <alexandru.croitor@qt.io> (cherry picked from commit 8b086b49b48e7c69413ce08aa534378e54633fe4)
* Cocoa: Allow CMD+H to hide the application when a tooltip is visibleAndy Shaw2020-11-101-1/+2
| | | | | | | | | | | | Since native applications allow CMD+H to hide an application when the tooltip is visible then we should do too. Other popup windows will still block the call. Fixes: QTBUG-82626 Change-Id: Ieac86d6b3cb2152a3ba82d8bd850f13bfeedb7c8 Reviewed-by: Tor Arne Vestbø <tor.arne.vestbo@qt.io> (cherry picked from commit 5f2b53f13c40c31da21d8352312962bb97cb8c97) Reviewed-by: Qt Cherry-pick Bot <cherrypick_bot@qt-project.org>
* Fix regular expression initialize with incorrect filtersZhang Yu2020-11-101-3/+3
| | | | | | | | | | | | | | | | | | | | The filters used to construct regular expression is the parameter of QDirIteratorPrivate constructor,and not the member variable 'filters' of QDirIteratorPrivate. When using filters as QDir::NoFilter to construct QDirIteratorPrivate, then the regular expression will incorrectly initialize with QDir::CaseSensitive(result of QDir::NoFilter),and not Qt::CaseInsensitive(result of QDir::AllEntries). Therefore, using the '_filters' to replace the parameter 'filters' Fixes: QTBUG-88227 Change-Id: I8a21fe1075fd95981e328a161a978e4fe546c9ca Reviewed-by: Simon Hausmann <hausmann@gmail.com> Reviewed-by: Oliver Wolff <oliver.wolff@qt.io> (cherry picked from commit f353519e78380c04cffecfa4ceef222f37e8d83a) Reviewed-by: Qt Cherry-pick Bot <cherrypick_bot@qt-project.org>
* Reduce memory reallocations in QTextTablePrivate::update()Robert Loehning2020-11-092-14/+6
| | | | | | | | | | | This fixes oss-fuzz issue 21100. Task-number: QTBUG-85139 Change-Id: I635c1fa9b16dd527e568ec1e98ea7cac73977020 Reviewed-by: Giuseppe D'Angelo <giuseppe.dangelo@kdab.com> Reviewed-by: Lars Knoll <lars.knoll@qt.io> (cherry picked from commit 07aa91221fb436d5c3fb8cbc72428b85714c576a) Reviewed-by: Shawn Rutledge <shawn.rutledge@qt.io>
* Fix compilation when using -no-mimetype-databaseHelio Chissini de Castro2020-11-091-0/+4
| | | | | | | Change-Id: I4f706a26d73f61e4a6022338e0fc0be48627e4a1 Reviewed-by: Thiago Macieira <thiago.macieira@intel.com> Reviewed-by: David Faure <david.faure@kdab.com> (cherry picked from commit c67ea659e5447fc2d898dbb78189bfe22893522c)