summaryrefslogtreecommitdiffstats
path: root/src
Commit message (Collapse)AuthorAgeFilesLines
* Update the DNS public suffix list from publicsuffix.orgEdward Welbourne2018-10-161-13288/+13692
| | | | | | | | | | It has had some changes and should be kept up to date. Task-number: QTBUG-70852 Change-Id: I868a558811c34cf5a800c3087a0ca96e7fb49b1a Reviewed-by: Mårten Nordheim <marten.nordheim@qt.io> Reviewed-by: Allan Sandfeld Jensen <allan.jensen@qt.io> (cherry picked from commit ba0ff45109a0eb051a42d6d8392d1f1b7a1e9345)
* Fix font weights on macOS 10.14James Turner2018-10-121-3/+3
| | | | | | | | | | | | | | | | | | | | On later versions of macOS, the font weight trait of fonts is a 64 bit double, not a 32 bit float, and on macOS 10.14, CFNumberGetValue() started returning false for values when the type conversion is lossy, like it is documented to. Therefore, we would end up without weight information in 10.14. The fix is to ask for a double instead, which works regardless of whether the CFNumber represents a 32-bit or 64-bit value. [ChangeLog][macOS][Text] Fixed font weights on macOS 10.14 Task-number: QTBUG-69955 Change-Id: Ia0577236ddc6b96f9231e6de7b1c49f7f8a837a6 Reviewed-by: Tor Arne Vestbø <tor.arne.vestbo@qt.io> Reviewed-by: Jason Haslam <jason@scitools.com> Reviewed-by: Eskil Abrahamsen Blomfeldt <eskil.abrahamsen-blomfeldt@qt.io> (cherry picked from commit 9601ad4e27d0e0a846ff13a1e7dbadd7afd260f5)
* Fix glext and gles2ext attributionLaszlo Agocs2018-10-102-5/+5
| | | | | | Task-number: QTBUG-70903 Change-Id: I980d9cdd12a0d7565e36a38814b0e85a857bd2b7 Reviewed-by: Alex Blasche <alexander.blasche@qt.io>
* doc: Document version of bundled Freetype in qt_attributionEskil Abrahamsen Blomfeldt2018-10-051-0/+2
| | | | | | Task-number: QTBUG-70901 Change-Id: Ie7531ceb4d529f45e848d39732bb3402f4a70cbb Reviewed-by: Simon Hausmann <simon.hausmann@qt.io>
* Windows QPA: Don't test for Desktop GL if Qt::AA_UseDesktopOpenGL is setFriedemann Kleint2018-10-023-24/+19
| | | | | | | | | | | Pass the requested render to detectSupportedRenderers(), replacing the bool glesOnly parameters. This allows for simplifying the code. Fixes: QTBUG-70733 Change-Id: Iab65f62d24bf750019180e3b00e2d23c105e5997 Reviewed-by: Laszlo Agocs <laszlo.agocs@qt.io> (cherry picked from commit 05e2690009553d3faaf04ef8927fc072c652dd52) Reviewed-by: Pasi Petäjäjärvi <pasi.petajajarvi@qt.io>
* QMenuBar: Account for displays that are above 0x0Andy Shaw2018-09-261-1/+1
| | | | | | | | | | | | | | If a display is placed above a primary screen which has the top left set to be 0x0, then menus that are defaulting to go up can still be displayed on that screen when the menubar is placed on the bottom of it. This ensures that this is the case and also adds a manual test to aid verification of it in the future. Change-Id: Ib657ccdc1aabfe1586c72585c087ac80a6c632c2 Reviewed-by: Friedemann Kleint <Friedemann.Kleint@qt.io> (cherry picked from commit 34d212cb02f168e59c2a5c8e95a12377a57bfb7e) Reviewed-by: Richard Moe Gustavsen <richard.gustavsen@qt.io>
* QWin32PrintEngine: Fix crash in drawPixmap(), drawImage()Friedemann Kleint2018-09-241-8/+2
| | | | | | | | | | | | | Use the printer's HDC instead of the screen HDC for StretchBlt(). Patch as contributed via bug report. Task-number: QTBUG-59689 Task-number: QTBUG-66325 Change-Id: I9b5d6ddd3f0e9e68f2a003ca9ed20ece20dccef8 Reviewed-by: Andy Shaw <andy.shaw@qt.io> (cherry picked from commit 7aaa7debc455516cbb1b1f536e990b9154272f64) Reviewed-by: Friedemann Kleint <Friedemann.Kleint@qt.io>
* bmp image handler: check for out of range image sizeEirik Aavitsland2018-09-241-0/+2
| | | | | | | | | | Make the decoder fail early to avoid spending time and memory on attempting to decode a corrupt image file. Change-Id: I874e04f3b43122d73f8e58c7a5bcc4a741b68264 Reviewed-by: Lars Knoll <lars.knoll@qt.io> (cherry picked from commit 621ab8ab59901cc3f9bd98be709929c9eac997a8) Reviewed-by: Liang Qi <liang.qi@qt.io>
* Fix integer overflow in very long sections in ELF objectsThiago Macieira2018-09-241-1/+1
| | | | | | | | | | | | | | The source is an ElfXX_Off, which is an unsigned 32- or 64-bit. That means any section bigger than 2 GB would cause an overflow when we assigned in m_stringTableFileOffset = strtab.offset; Change-Id: Ib47c56818178458a88b4fffd15546bd47a89894e Fixes: QTBUG-70560 Reviewed-by: Olivier Goffart (Woboq GmbH) <ogoffart@woboq.com> (cherry picked from commit cb5c24fa26142edaff8fd2c9787dbe45c222b4ff) Reviewed-by: Jędrzej Nowacki <jedrzej.nowacki@qt.io>
* Windows: Fix MDI child window titles in High-DPI displaysAndre de la Rocha2018-08-302-20/+24
| | | | | | | | | | | | | | This change improves the appearance of MDI child windows in a High-DPI display for applications using the WindowsVista style, with the Qt::AA_EnableHighDpiScaling attribute set. Task-number: QTBUG-64708 Change-Id: I5e9fbd23809b440ffd33e4948c83d115cc6e1910 Reviewed-by: Friedemann Kleint <Friedemann.Kleint@qt.io> Reviewed-by: Alessandro Portale <alessandro.portale@qt.io> (cherry picked from commit 0b9a301e89c6473091a9b80552d6e4058d35bbe6) Reviewed-by: Alex Blasche <alexander.blasche@qt.io> Reviewed-by: Richard Moe Gustavsen <richard.gustavsen@qt.io>
* Update CLDR to v31.0.1, test Costa Rican currency's fractional partEdward Welbourne2018-08-282-4535/+4580
| | | | | | | | | | | | | | | CLDR up to somewhere between v29 (used by 5.9) and v31.0.1 (used by 5.10 and later) claimed Costa Ricans don't include fractions in their currency; now it claims they expec two digits. Apparently one of them does expect those two digits, so this adds a regression test (the cherry-pick) and updates CLDR to 31.0.1 (to make the test pass), along with needed fixes (as in 82deb0ad160) to some other tests. Task-number: QTBUG-70093 Change-Id: I138772cc6013fa74de4f7c54b836cac83421eab2 Reviewed-by: Thiago Macieira <thiago.macieira@intel.com> (cherry picked from commit dc7e775c9c6ecc66f76af8139b8dfc3ee101c7ff) Reviewed-by: Lars Knoll <lars.knoll@qt.io>
* Fix potential crash when showing line/paragraph separatorsEskil Abrahamsen Blomfeldt2018-08-211-1/+1
| | | | | | | | | | | | | | | | | | | | | | | When showing line and paragraph separators at an offset from the start of the string, the end of string pointer would be incorrectly set, and we would read past the end of the string. If any part of this memory happened to match the line or paragraph separator, then we would overwrite it and have a crash. I couldn't find any reliable way to test this, since the crash depends on the contents of the memory after the string allocated by the algorithm. But with an overflow of 100 000 characters, I found that it crashed every time I ran the test. [ChangeLog][QtGui][Text] Fixed potential crash when using QTextOption::ShowLineAndParagraphSeparators. Task-number: QTBUG-69661 Change-Id: I17d1996b883560bacdc7ce114c8aeb2b0108faea Reviewed-by: JiDe Zhang <zccrs@live.com> Reviewed-by: Michal Lazo <xlazom00@gmail.com> Reviewed-by: Konstantin Ritt <ritt.ks@gmail.com> (cherry picked from commit 65a1d41a092e78f7ab142c4c62689e1ca40ba10c)
* QObject: do allow setProperty() to change the type of the propertyThiago Macieira2018-08-211-1/+2
| | | | | | | | | | | | [ChangeLog][QtCore][QObject] Fixed a bug in setProperty() that caused a property change not to take effect if the old value compared equal using QVariant's equality operator, but the values were not strictly equal. Task-number: QTBUG-69744 Change-Id: I00e04a465fcf4fc1a462fffd1547885861a07a64 Reviewed-by: Simon Hausmann <simon.hausmann@qt.io> Reviewed-by: Olivier Goffart (Woboq GmbH) <ogoffart@woboq.com> (cherry picked from commit 64a560d977a0a511ef541d6116d82e7b5c911a92)
* QStyleHelper: Use palette cache key in pixmap keyGabriel de Dietrich2018-08-211-20/+1
| | | | | | | | | | | | | | | | | This reverts commit d7bcdc3a442b99c2caebd4cfd38de67e14090e05. Now that QPalette::setBrush() is a bit smarter (see c564779c071b35fddb76f4e50afda4305b634651), we can be confident the palette's cache key won't change so often. Therefore, we can use it again as part of every pixmap's cache key. Change-Id: I5cab2296a937f9149c7745291e0442eea24f4e9d Task-number: QTBUG-65475 Reviewed-by: Friedemann Kleint <Friedemann.Kleint@qt.io> Reviewed-by: Richard Moe Gustavsen <richard.gustavsen@qt.io> (cherry picked from commit 1e75dcf2518e37a7b83d006a4e002f972615b43b) Reviewed-by: Gabriel de Dietrich <gabriel.dedietrich@qt.io>
* Fix possible heap corruption in QXmlStreamAllan Sandfeld Jensen2018-08-181-1/+1
| | | | | | | | | | The value of 'tos' at the check might already be on the last element, so triggering stack expansion on the second last element is too late. Change-Id: Ib3ab2662d4d27a71effe9e988b9e172923af2908 Reviewed-by: Richard J. Moore <rich@kde.org> Reviewed-by: Thiago Macieira <thiago.macieira@intel.com> (cherry picked from commit 6256729a6da532079505edfe4c56a6ef29cd8ab8)
* Doc: Increase precision in description of convenience typedefsPaul Wicking2018-08-161-1/+1
| | | | | | | Task-number: QTBUG-53856 Change-Id: I57917bb311d1d93e0903f2b3e021cc4db0f0d05e Reviewed-by: Nico Vertriest <nico.vertriest@qt.io> (cherry picked from commit d2d59e77d5e16bc79ddfed37f4f29d1dcd9b92a7)
* Fix MSVC2017 compilation with enabled relaxed constexpr on 32-bit targetOlivier Goffart2018-08-151-4/+6
| | | | | | | | | | | | | | | | | | | | | | The problem is that qCountLeadingZeroBits is calling qPopulationCount which is only conditionally constexpr, so qCountLeadingZeroBits can only be marked constexpr if qPopulationCount is also. On MSVC2017 64bit this is not a problem because it uses builtins function in this case. (which is not constexpr, but it works because the compiler is not forced to diagnose the problem because of the "?:" operator. The error being fixed is: qalgorithms.h(847): error C3615: constexpr function 'qCountLeadingZeroBits' cannot result in a constant expression qalgorithms.h(858): note: failure was caused by call of undefined function or one not declared 'constexpr' qalgorithms.h(858): note: see usage of 'qPopulationCount' Task-number: QTBUG-67259 Change-Id: I65a3dfae12ca49394bec14ffefdd41a07fee1c32 Reviewed-by: Thiago Macieira <thiago.macieira@intel.com> (cherry picked from commit c59cb9809559f0aae6be8544cb2049e41f8040e9) Reviewed-by: Ville Voutilainen <ville.voutilainen@qt.io>
* Make QPalette::setBrush() check before detachingGabriel de Dietrich2018-08-141-15/+17
| | | | | | | | | | | | | Setting the same brush on the same group and role should not detach nor alter the result of QPalette::isCopyOf(). Task-number: QTBUG-56743 Change-Id: Ic2d0dd757d703b01e8c5d835a8c124b3317653f4 Reviewed-by: Friedemann Kleint <Friedemann.Kleint@qt.io> Reviewed-by: Andy Shaw <andy.shaw@qt.io> Reviewed-by: Richard Moe Gustavsen <richard.gustavsen@qt.io> (cherry picked from commit c564779c071b35fddb76f4e50afda4305b634651) Reviewed-by: Tor Arne Vestbø <tor.arne.vestbo@qt.io>
* Revert "Fix restoring geometry of dockwidget"R.J.V. Bertin2018-08-132-19/+2
| | | | | | | | | | | | | This reverts commit cbfb6bda1d1ce3e169db6a0deb9bd901076653e4. That fix for QTBUG-16252 should not have been applied to the 5.9 branch. It also introduced a regression (QTBUG-68939). Task-number: QTBUG-68939 Task-number: QTBUG-16252 Change-Id: I71732de739788337fcd46ed8ac4ecfef1ef6e239 Reviewed-by: André Hartmann <aha_1980@gmx.de> Reviewed-by: Olivier Goffart (Woboq GmbH) <ogoffart@woboq.com> Reviewed-by: Bastiaan Veelo <Bastiaan@SARC.nl>
* cocoa: Don’t trigger security dialog on dragMorten Johan Sørvig2018-08-081-1/+5
| | | | | | | | | | macOS 10.14+ will display an “Accessibility Access” security dialog if we generate mouse events, so don’t. Task-number: QTBUG-68830 Change-Id: If832ca3cd49ec6bdad1a8188feab884b6562e9d2 Reviewed-by: Tor Arne Vestbø <tor.arne.vestbo@qt.io> (cherry picked from commit cd08753d3e2ac02663ba0ab588d7d926f7438475)
* Check for QImage allocation failure in qgifhandlerEirik Aavitsland2018-08-071-1/+6
| | | | | | | | | Since image files easily can be (or corrupt files claim to be) huge, it is worth checking for out of memory situations. Change-Id: I635a3ec6852288079fdec4e14cf7e776fe59e9e0 Reviewed-by: Lars Knoll <lars.knoll@qt.io> (cherry picked from commit 2841e2b61e32f26900bde987d469c8b97ea31999)
* Fix crash in qppmhandler for certain malformed image filesEirik Aavitsland2018-08-071-1/+1
| | | | | | | | | | | The ppm format specifies that the maximum color value field must be less than 65536. The handler did not enforce this, leading to potentional overflow when the value was used in 16 bits context. Task-number: QTBUG-69449 Change-Id: Iea7a7e0f8953ec1ea8571e215687d12a9d77e11c Reviewed-by: Lars Knoll <lars.knoll@qt.io> (cherry picked from commit 8c4207dddf9b2af0767de2ef0a10652612d462a5)
* Doc: Fix wrong link in QFont documentationPaul Wicking2018-08-061-1/+1
| | | | | | | Task-number: QTBUG-62072 Change-Id: I587534fc5723b3d198fe2065fbcf1bee4871a768 Reviewed-by: Mitch Curtis <mitch.curtis@qt.io> (cherry picked from commit ae289884db05cbaac71156983974eebfb9b59730)
* QJsonDocument: Make emptyObject an objectJüri Valdmann2018-08-061-1/+1
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | A default-constructed QJsonObject has no data payload, it is only a pair of null pointers. So, when it becomes necessary to 'materialize' such an object, a special global emptyObject constant is used as the substitute payload. There is a small problem with this global constant though, namely that it's is_object flag is unset. In other words, the emptyObject is not an object, but an array. Fix by setting the is_object flag on emptyObject. The example code in the bug report QJsonObject parent; QJsonObject child; parent["child"] = child; // 1 child = parent["child"].toObject(); // 2 child["test"] = "test"; // 3 runs into this problem on line 1. Inserting the default-constructed child means inserting a copy of emptyObject. On line 2 a pointer to this copy of emptyObject is retrieved and cast to an object. But it's not an object, it's an array, so things go wrong hereafter. Specifically, on line 3, two inserts are performed, one from operator[] and one from operator=. Each insert increments a compaction counter. The second insert triggers compaction (QJsonObject::insert calls Value::requiredStorage calls Data::compact) and compaction branches based on the is_object flag. Replacing line 3 with child.insert("test", "test"); causes the example to appear to work since compaction is not triggered and the JSON serializer does not look at the is_object flag. Still, any further insert() calls would trigger compaction and memory corruption. Task-number: QTBUG-69626 Change-Id: I8bd5174dce95998bac479c4b4ffea70bca1a4d04 Reviewed-by: Lars Knoll <lars.knoll@qt.io> (cherry picked from commit f43e947dc405b6a2324656f631c804db8e8dec3d)
* Doc: Update out-of-date image in QColorDialog documentationPaul Wicking2018-08-041-0/+0
| | | | | | | Task-number: QTBUG-58420 Change-Id: Ib5c7a3f681b082182cf6ec9aa62028b7040e81bf Reviewed-by: Martin Smith <martin.smith@qt.io> (cherry picked from commit c6cca0f492717582cb113f3d62e97f554798cf14)
* Doc: Remove reference to QTestEventPaul Wicking2018-08-011-5/+2
| | | | | | | | | | | QTestEventList refers to QTestEvent, which is an implementation detail that should not appear in documentation. Task-number: QTBUG-68109 Change-Id: Id132889427b757ea17165c8b15ed47bcfb9e1c3f Reviewed-by: Mitch Curtis <mitch.curtis@qt.io> (cherry picked from commit e386cd03d12e401b9e3945602e9621a86009fa11)
* Doc: Make reference to platform styles version agnosticPaul Wicking2018-07-311-4/+3
| | | | | | | | | Remove platform/version specific reference to avoid outdated docs. Task-number: QTBUG-64304 Change-Id: Ief9d5db95fa1f865fd826a6426b1621e81bdb6ce Reviewed-by: Venugopal Shivashankar <Venugopal.Shivashankar@qt.io> (cherry picked from commit fdb780b897fc2964dc70c286ee3102d7ce6327ea)
* Fix the copyright attribution for the HarfBuzz dependencyNicolas Ettlin2018-07-241-7/+5
| | | | | | | Task-number: QTBUG-69260 Change-Id: I03079bee5eb17f87f48690e800517831f6215975 Reviewed-by: Kai Koehne <kai.koehne@qt.io> (cherry picked from commit 7d05144dde55ab0519e5dd1e441547456a28d80e)
* Update bundled sqlite to 3.24.0Kai Koehne2018-07-173-10756/+22883
| | | | | | | | | [ChangeLog][Third-Party Code] Sqlite was updated to version 3.24.0 Task-number: QTBUG-69274 Change-Id: Icf3d7b2c1af0fb67033fd39240bee0cacccaf96f Reviewed-by: Andy Shaw <andy.shaw@qt.io> (cherry picked from commit 46c2241a57d65ae6bb89e0924cadb3220e5371ef)
* Fix the copyright year of the qgrayraster.c dependencyNicolas Ettlin2018-07-121-1/+1
| | | | | | | | | | | | The copyright year of the qgrayraster.c dependency was incorrectly set to “2006-2015”, instead of 2000-2016 (as stated in the file’s header comments). This commit solves this issue. Task-number: QTBUG-69261 Change-Id: I307b6eabdd133fe4f8371b963577b59af8620838 Reviewed-by: hjk <hjk@qt.io> (cherry picked from commit 94a65fb23210a60e286de0f13a6f31af475f1950) Reviewed-by: Kai Koehne <kai.koehne@qt.io>
* Flush the initial clear blit with SCREEN_WAIT_IDLEJames McDonnell2018-07-061-1/+1
| | | | | | | | | | | Without it, the clear runs asynchronously and screen may clear pixels _after_ Qt updates them. Change-Id: I0c0844676d8a4387439a2f818ee08942ccaf6b08 Reviewed-by: Dan Cape <dcape@qnx.com> Reviewed-by: Janne Koskinen <janne.p.koskinen@qt.io> Reviewed-by: Rafael Roquetto <rafael.roquetto@kdab.com> (cherry picked from commit 8bcb8b069e9a35226c1465265d4d716c864dde54)
* Fix compile with sanitize address & undefinedBogDan Vatra2018-06-261-1/+5
| | | | | | | | | | | | | On Debian 9, the sanitize library exports only dlopen symbol, but it doesn't export the other ones. We need to check all dl symbols that we use, otherwise "-ldl" will not be added to the libs list. Task-number: QTBUG-64864 Change-Id: I3e62b82985348c40b8b61302ba589d5564598e18 Reviewed-by: Oswald Buddenhagen <oswald.buddenhagen@qt.io> (cherry picked from commit b2d2b655e58d5337765c26dafa836b12e019c6a4) Reviewed-by: BogDan Vatra <bogdan@kdab.com>
* VNC plugin: explicitly cast int to uint16_t before calling htonsShawn Rutledge2018-05-251-3/+3
| | | | | | | | | | Otherwise there is a -Werror=narrowing error on big-endian architectures (where htons does nothing). Task-number: QTBUG-68390 Change-Id: Idb204a81aaedb9f4fde1d5fae406da36c7a1953e Reviewed-by: Thiago Macieira <thiago.macieira@intel.com> (cherry picked from commit b206d1c8082a9e01ad3755d311a4cf683ec35161)
* QJsonDocument: Avoid overflow of string lengthsJüri Valdmann2018-05-161-23/+20
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | The added test case contains the binary JSON equivalent of ["ž"] with the modification that the string's length has been set to INT_MAX. In Value::usedStorage this length is used through the pointer d like so s = sizeof(int) + sizeof(ushort) * qFromLittleEndian(*(int *)d); Because 2 * INT_MAX is UINT_MAX-1, the expression as a whole evaluates to 2, which is considered a valid storage size. However, when converting this binary JSON into ordinary JSON we will attempt to construct a QString of length INT_MAX. Fixed by using String::isValid instead of Value::usedStorage. This method already takes care to avoid the overflow problem. Additionally, I've tried in this patch to clarify the behavior of Value::isValid a bit by writing it in a style that is hopefully more amenable to structural induction. Finally, the test case added in my previous patch had the wrong file extension and is renamed in this one. Task-number: QTBUG-61969 Change-Id: I45d891f2467a71d8d105822ef7eb1a73c3efa67a Reviewed-by: Thiago Macieira <thiago.macieira@intel.com> (cherry picked from commit 8e47474baf06b3884e9173302395dd25fc09eba9) Reviewed-by: Lars Knoll <lars.knoll@qt.io>
* QJsonDocument: Validate also zero-length objectsJüri Valdmann2018-05-161-2/+0
| | | | | | | | | | | | | | | | | | | | | | | | | | The added test case is the binary JSON equivalent of {"a":{"š":null}} with two modifications. First, the length of the string "š" has been corrupted to 0xFFFFFF00. Second and more import, the Base::size field of the inner object has been reset to 0. On its own the first modification would normally trigger a validation error. However, due to the second modification the Value::usedStorage for the inner object evaluates to 0, completely disabling all further validation of the object's contents. Attempting to convert this binary JSON into standard JSON will lead to the JSON writer trying to construct a QString of length 0xFFFFFF00. Fixed by validating also objects with usedStorage == 0. Task-number: QTBUG-61969 Change-Id: I5e59383674dec9be89361759572c0d91d4e16e01 Reviewed-by: Thiago Macieira <thiago.macieira@intel.com> (cherry picked from commit 93e0ff037e3e4d72d404c26b8e957092d5f88652) Reviewed-by: Lars Knoll <lars.knoll@qt.io>
* QJsonDocument: Reject objects containing themselves in binary JSONJüri Valdmann2018-05-161-3/+3
| | | | | | | | | | | | The added test case is a binary JSON file describing an array which contains itself. This file passes validation even though attempting to convert it to plain JSON leads to an infinite loop. Fixed by rejecting it in validation. Task-number: QTBUG-61969 Change-Id: Ib4472e9777d09840c30c384b24294e4744b02045 Reviewed-by: Lars Knoll <lars.knoll@qt.io> (cherry picked from commit 3fc5500b4f2a8431ac013520e9faf606e893b39a) Reviewed-by: Thiago Macieira <thiago.macieira@intel.com>
* QJsonDocument::fromRawData: Fix out-of-bounds accessJüri Valdmann2018-05-162-1/+4
| | | | | | | | | | | | | | | This method takes a pointer+size pair, but begins reading through the pointer without first checking the size parameter. Fixed by checking the size parameter. A new test case is added with an empty binary json file. Although the test does not fail under normal conditions, the problem can be detected using valgrind or AddressSanitizer. Task-number: QTBUG-61969 Change-Id: Ie91cc9a56dbc3c676472c614d4e633d7721b8481 Reviewed-by: Lars Knoll <lars.knoll@qt.io> Reviewed-by: Thiago Macieira <thiago.macieira@intel.com> (cherry picked from commit d3935cbd71171e1d8f3742cc3235ca0c38313ec8)
* macOS + FreeType: Properly distinguish memory fonts from file fontsTor Arne Vestbø2018-05-151-6/+5
| | | | | | | | | | | | | | | | | | In recent macOS versions the descriptor created from the function CTFontManagerCreateFontDescriptorFromData() will contain the NSCTFontFileURLAttribute with a value such as: file://iNmEmOrYcGfOnT_0x101d3c3a0#postscript-name=New Which means we can't use the presence of the kCTFontURLAttribute to determine that we're dealing with a file font. Instead we check for our custom kQtFontDataAttribute first, which is only set for memory fonts. Task-number: QTBUG-68044 Change-Id: Ie87d06b5a9e0e251305200b717f18ef68ccc6abc Reviewed-by: Eskil Abrahamsen Blomfeldt <eskil.abrahamsen-blomfeldt@qt.io> (cherry picked from commit 43ea15d01cd491639d8cb5eb85da066f5d0a8571)
* Fix build without features.timezoneTasuku Suzuki2018-05-151-0/+4
| | | | | | Change-Id: I3f8421103afa61baf415636b4dc8cf93fb477bcc Reviewed-by: Oswald Buddenhagen <oswald.buddenhagen@qt.io> (cherry picked from commit 8f7dcba204d21444cb0bd00f13fc496bb9420484)
* Windows/QSaveFile: Fix locking issues on Dropbox drivesFriedemann Kleint2018-05-143-5/+13
| | | | | | | | | | | | | | | Add a flag to QTemporaryFileEngine causing the file to be opened in non-shared mode, preventing renaming failures caused by the Dropbox driver accessing it. Task-number: QTBUG-57299 Change-Id: Id7afc3559fd15784d4166efbbd057d592b5e0ab2 Reviewed-by: Oswald Buddenhagen <oswald.buddenhagen@qt.io> Reviewed-by: Oliver Wolff <oliver.wolff@qt.io> Reviewed-by: Thiago Macieira <thiago.macieira@intel.com> (cherry picked from commit fe5edcee602f0ab2912bbdd1a21f4309ed7dbfd6) Reviewed-by: Frederik Gladhorn <frederik.gladhorn@qt.io> Reviewed-by: Kai Pastor <dg0yt@darc.de>
* Fix crash if QPixmap::defaultDepth() is called when no QGuiApplicationEirik Aavitsland2018-04-191-1/+7
| | | | | | | | | | | This static method can be called before QGuiApplication is created. At that point there is yet no primary screen, so the implementation needs to guard against dereferencing a nullptr. Task-number: QTBUG-67309 Change-Id: I6b7b9e97b1c3c79bf2f9c6d6247c3b10f39f7a55 Reviewed-by: Friedemann Kleint <Friedemann.Kleint@qt.io> (cherry picked from commit 7f782e1fc41ff7694f9bf7434d5a4db0545c0413)
* macOS: Fix standardLocations() returns invalid pathMasashi Fujimoto2018-04-161-20/+9
| | | | | | | | | | | | | | | | | | | | | | | | The file path included in the return value was incorrect when giving the following value to the argument of "QStandardPaths::standardLocations()". - QStandardPaths::AppDataLocation - QStandardPaths::AppLocalDataLocation - QStandardPaths::DataLocation The function to obtain the path to <AppName>.app changed from CFURLCopyPath() to CFURLCopyFileSystemPath() by commit id c0da37a806dc0457636d787331e9f50778ee8b3e. CFURLCopyPath() returns a value with a path delimiter appended at the end, but CFURLCopyFileSystemPath() is not. This is a commit to append '/' to the end of the return value of CFURLCopyFileSystemPath(). Task-number: QTBUG-61159 Change-Id: Icaebdf09d9cdf992d59c16a398dfe666e6225f99 Reviewed-by: Jake Petroules <jake.petroules@qt.io> (cherry picked from commit aebc9023bb0acb9697540b444a6dfae95b762644) Reviewed-by: Tor Arne Vestbø <tor.arne.vestbo@qt.io>
* QCoreTextFontEngine: Fix build with Xcode 9.3Gabriel de Dietrich2018-04-121-1/+1
| | | | | | | | | | | | | | | Apple LLVM version 9.1.0 (clang-902.0.39.1) Error message: .../qfontengine_coretext.mm:827:20: error: qualified reference to 'QFixed' is a constructor name rather than a type in this context return QFixed::QFixed(int(CTFontGetUnitsPerEm(ctfont))); Change-Id: Iebe26b3b087a16b10664208fc8851cbddb47f043 Reviewed-by: Konstantin Ritt <ritt.ks@gmail.com> (cherry-picked from commit dbdd5f0ffbce52c8b789ed09f1aa3f1da6c02e23) Reviewed-by: Morten Johan Sørvig <morten.sorvig@qt.io>
* Merge remote-tracking branch 'origin/5.9.5' into 5.9Qt Forward Merge Bot2018-04-113-6/+8
|\ | | | | | | Change-Id: Iee7af16c3e26dc7d7f594ebd3876370ac83a1bc8
| * QFusionStyle: Fix compilation when qreal is floatAlexander Akulich2018-03-201-4/+4
| | | | | | | | | | | | | | | | Change-Id: I575d348915a7239a40b589012b4e9707bd15d1dd Reviewed-by: Friedemann Kleint <Friedemann.Kleint@qt.io> Reviewed-by: Olivier Goffart (Woboq GmbH) <ogoffart@woboq.com> (cherry picked from commit 53f82185e9320e0561d5a424d7145aadc18cca30) Reviewed-by: Yulong Bai <yulong.bai@qt.io>
| * Revert "Set sharedPainter correctly for QGraphicsEffect"Laszlo Agocs2018-03-201-2/+2
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | This reverts commit 7257862fb2edfab0219d6cd45c83677049404f7d. It has been reported that this patch causes widgets with certain effects become invisible. Task-number: QTBUG-60231 Task-number: QTBUG-66803 Task-number: QTBUG-66387 Change-Id: I9c3c4cf2f17ac639d1aee5489b665aa1e165af16 Reviewed-by: Friedemann Kleint <Friedemann.Kleint@qt.io> (cherry picked from commit 00304eac7b1ddd22b971da78aa84c86fe2919359) Reviewed-by: Eike Ziller <eike.ziller@qt.io>
| * Merge 5.9 into 5.9.5Oswald Buddenhagen2018-03-1434-128/+109
| |\ | | | | | | | | | Change-Id: I327bacd544f874da37c4e0740af0c7854d74a913
| * | Fix QLabel crash if buddy's lifetime is too shortSergio Martins2018-03-121-0/+2
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | If buddy is deleted then QLabel will still try to deliver the shortcut event to it, in QLabel::event(), and crash. For this cherry-pick removed all nice-to-haves and only fixed dereferencing the null pointer. Task-Id: QTBUG-66841 Change-Id: Ib6a36a9f99cee31afe1f88eb77f5b6cafb8b1086 Reviewed-by: Olivier Goffart (Woboq GmbH) <ogoffart@woboq.com> (cherry picked from commit c082d84d5d7fdbfb64de18f06a8ddbc77f2e6de4) Reviewed-by: Christoph Schleifenbaum <christoph.schleifenbaum@kdab.com> Reviewed-by: Milian Wolff <milian.wolff@kdab.com>
* | | Fix integer overflow (1 << (' ' - 1))Mikhail Svetkin2018-04-101-7/+7
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | On platforms where integer by default is int32(max is 2147483647) and (1 << (' ' - 1)) will be 2147483648 Change-Id: I790d33bd4e473925d6897dd87cbffdfe8dd7938f Reviewed-by: Thiago Macieira <thiago.macieira@intel.com> Reviewed-by: Edward Welbourne <edward.welbourne@qt.io> (cherry picked from commit 28f9b35b35e7c9964f22f4e28aac9c6093401900)
* | | Fix integer overflow (1 << 31)Mikhail Svetkin2018-04-101-1/+1
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | On platforms where integer by default is int32(max is 2147483647) and (1 << 31) will be 2147483648 Change-Id: I59ccb5344d5ad7d085f01bbc7cebdf6152ff7755 Reviewed-by: Jesus Fernandez <Jesus.Fernandez@qt.io> Reviewed-by: Edward Welbourne <edward.welbourne@qt.io> Reviewed-by: Thiago Macieira <thiago.macieira@intel.com> (cherry picked from commit f5a624c9b94455bebd7eb8fabbb300c4793fe6df)