QSharedDataPointer obeys the regular Qt container thread-safety rules:
it's thread-safe in const methods but not in mutating ones. QSDP::data()
is mutating, which causes a data race. For example, if the contained
QLocalePrivate has a refcount of 2 and two threads see that, both
threads will try to detach and then replace the pointer, but that
pointer replacement is not atomic.
Using QExplicitSharedDataPointer makes the race go away, since data() is
now non-mutating. QESDP is used only to destroy the QLocalePrivate on
program shutdown.
Note that there are still race conditions relating to *updating* the
locale private.
Fixes: QTBUG-73403
Change-Id: Id98140e1c2f0426cabbefffd157ed6ec30a3e08f
Reviewed-by: Thomas Sondergaard <thomas@sondergaard.cc>
Reviewed-by: Edward Welbourne <edward.welbourne@qt.io>
Only for tests that have existing expected_*.* files for other
formats, though.
Change-Id: I34ca1900d88454f300e04d849a608c378009489b
Reviewed-by: Tor Arne Vestbø <tor.arne.vestbo@qt.io>
Google removed this support long tima ago, also we removed it from QtCreator.
Change-Id: I326da09e9e57f655eecfd1f25f39b4bd9c6784d1
Reviewed-by: Eskil Abrahamsen Blomfeldt <eskil.abrahamsen-blomfeldt@qt.io>
When spliting the patch the edit become an addition instead.
Task-number: QTBUG-72785
Change-Id: I92105d0e23e9b8426228f4202d46fa41f928fb94
Reviewed-by: Christian Andersen <csandersen3@gmail.com>
Reviewed-by: Gatis Paeglis <gatis.paeglis@qt.io>
Where non-format characters appear in the format string, they are not
"ignored" as claimed; they are passed through verbatim. Formats
without separators between fields are in fact supported, although
results may be ambiguous. Cleaned up phrasing in the process.
Fixes: QTBUG-51208
Change-Id: I7284a36c48aa0be29deaa16945ca0212e9e6f72c
Reviewed-by: Paul Wicking <paul.wicking@qt.io>
Regexes have long specified that a [ as the first character inside a
[...] is just a literal [, but apparently we need to escape it now, to
avoid a "nested set" FutureWarning.
Change-Id: I76a48c9aafb0684a1d6b0d5284fe9852c9ea0e43
Reviewed-by: Friedemann Kleint <Friedemann.Kleint@qt.io>
Reviewed-by: Samuel Gaist <samuel.gaist@idiap.ch>
It was incorrectly counting a block having more than one line as having
changed visibility.
Fixes: QTBUG-69310
Change-Id: I502cda1d3e8a4efb1c14122353cc0a4731d8581c
Reviewed-by: Richard Moe Gustavsen <richard.gustavsen@qt.io>
This is required to support the new emoji font on Android 9.
[ChangeLog][Freetype] Upgraded bundled Freetype version to 2.9.1.
This also adds support for the latest emoji font in use on
Android 9.
Fixes: QTBUG-70657
Change-Id: I99be72f0d23c20aca122b8fdadd4ded87b2edce1
Reviewed-by: Konstantin Ritt <ritt.ks@gmail.com>
OpenSSL 1.1.0 and higher requires SSL_shutdown to mark a
session as resumable.
QHttpNetworkConnection/Channel tries to re-use one shared SSL
context (and the session) for its 'channels'. The session is
marked as non-resumable without shutdown sent/received.
This makes it useless for QHttpNetworkConnection.
See: https://github.com/openssl/openssl/issues/1550
Fixes: QTBUG-71967
Change-Id: Iaaceb18c4c5a090f997f9850981a27f04f1f8b06
Reviewed-by: Edward Welbourne <edward.welbourne@qt.io>
Reviewed-by: Timur Pocheptsov <timur.pocheptsov@qt.io>
For some reason, displayRectIgnoringOpacity renders NSBox with a
smaller height than we asked. So let's ask for more and translate.
Change-Id: I6e03ad99d1ccf746c89d58dd37d53d0087f15282
Fixes: QTBUG-71741
Reviewed-by: Tor Arne Vestbø <tor.arne.vestbo@qt.io>
Like we do with fully matching format, pick the first matching one,
instead of the last matching one.
Fixes: QTBUG-72785
Change-Id: I466e0152a229348b6a3786d5464d1f8ab325d67a
Reviewed-by: Gatis Paeglis <gatis.paeglis@qt.io>
Only the first successful query was stored in the variable. When a new
query is executed the function QSqlResult::setActive was not replacing
the last executed query.
Fixes: QTBUG-28883
Change-Id: Ib4938c42e6264f9edd0764b4a392da7988f68fc0
Reviewed-by: Andy Shaw <andy.shaw@qt.io>
QPictureIO::read() is using pictureFormat() when the format has to be
guessed. pictureFormat() returns a QByteArray which was implicit
casted into a char* and then pointed to uninitialized memory.
Fix it by using a QByteArray instead a plain char*.
Change-Id: If9ae286ed68134af597f0b0c779789e40f9efaed
Reviewed-by: Thiago Macieira <thiago.macieira@intel.com>
Unused resources
----------------
Unused resources make applications larger and slow down builds.
Amends e3689949ba. The string
was introduced there but not added to the manifest.
Task-number: QTBUG-72895
Change-Id: Id07e02074feb15ace2c99e6ace51d8fe407877fa
Reviewed-by: Eskil Abrahamsen Blomfeldt <eskil.abrahamsen-blomfeldt@qt.io>
The object role may in some cases (e.g. when using
Qt Quick Loaders) be changed after construction, and
we don’t have RoleChanged events.
Change-Id: Idb246c1c1206221cacd93c83cbd07a0e3d98cb0e
Fixes: QTBUG-72967
Reviewed-by: Frederik Gladhorn <frederik.gladhorn@qt.io>
Reviewed-by: Jan Arve Sæther <jan-arve.saether@qt.io>
When a QRawFont is set explicitly on the layout, we would get certain
font properties from the QTextCharFormat instead. But when the properties
had not been set on the QTextCharFormat, we would get the default values
which were always 0/false, not the actual default values used in QFont.
Instead, we calculate a QFont query based on the format and use the
properties from this. This will give us the correct default values
in the cases where they are not overridden.
Change-Id: I53e5103739164c3d9eafaf76fcb4e8bda57bd12a
Reviewed-by: Lars Knoll <lars.knoll@qt.io>
Prioritize blacklisting over QEXPECT_FAIL so that a test that is
blacklisted no longer fails if QEXPECT_FAIL returns true unexpectedly. To
reflect this state properly, the two values of BXPASS and BXFAIL were
added to testlib's output.
[ChangeLog][Important Behavior Changes][QtTestLib] Blacklisting of tests
will be taken into account for XPASS and XFAIL. A blacklisted test that
causes an XPASS will no longer be a fail.
Task-number: QTBUG-72928
Change-Id: Ia2232fdc714d405fa3fd9aea6c89eb2836bc5950
Reviewed-by: Edward Welbourne <edward.welbourne@qt.io>
Fixes the rest of the places we use the pattern of emptying the OpenGL
error stack to be able to handle GL_CONTEXT_LOST.
Change-Id: Ic45024fc6df84d70d60c48831fa586f889af0c0b
Reviewed-by: Allan Sandfeld Jensen <allan.jensen@qt.io>
Relying on QSurfaceFormat() to check whether or not we should set
the alpha channel size makes it impossible to tweak other properties
of the surface format without also having to set the alpha. There's
no need to do such as broad comparison, we can check the alpha channel
size for its default value instead.
Change-Id: Iac31d37c9460eb3e7ec5ee15902f7e5addb48178
Reviewed-by: Morten Johan Sørvig <morten.sorvig@qt.io>
Also catches some more variants of SDK mismatch, such as Xcode not
being installed at all, or the SDK missing.
Change-Id: I184aaa571ef0ea722ca64c54f665462dabc17533
Reviewed-by: Joerg Bornemann <joerg.bornemann@qt.io>
Reviewed-by: Timur Pocheptsov <timur.pocheptsov@qt.io>
Reviewed-by: Simon Hausmann <simon.hausmann@qt.io>
QPlatformGraphicsBuffer::byteCount() shouldn't need locking unless
bytesPerLine() is implemented in a way that requires it, in which
case the assert should be in the subclass.
Change-Id: I0fdb04c0a3ab042408d6d17b2759509853573d16
Reviewed-by: Laszlo Agocs <laszlo.agocs@qt.io>
Reviewed-by: Tor Arne Vestbø <tor.arne.vestbo@qt.io>
If configure is called with -continue, it should not stop processing
command line arguments after encountering an invalid one.
Example:
configure ... -continue -quack -no-feature-gui
would ignore everything after -quack.
Change-Id: Ia5f0cb13414c9c0c7246ff0c72f8e935fe6dca3c
Fixes: QTBUG-72912
Reviewed-by: Lars Knoll <lars.knoll@qt.io>
...and yield a warning that -skip has no effect in a qtbase build.
This is consistent with configure's help output and enables us to
always pass "-skip qtwhatnot", whether we're calling top-level or
qtbase configure.
Change-Id: Ie5b0791a6000d1d78b1367658ad86a92b2ec6a6a
Fixes: QTBUG-71253
Reviewed-by: Oliver Wolff <oliver.wolff@qt.io>
Reviewed-by: Kai Koehne <kai.koehne@qt.io>
In NDKr19 they removed "-strip-all-gnu" argument, now
llvm-strip prints tons of:
.../llvm-strip: error: unknown argument '-strip-all-gnu'.
Change-Id: I11bb2d6abcc5f236730c57b5b93cc932c7ba58c6
Reviewed-by: Andy Shaw <andy.shaw@qt.io>
It seems the pointer message handler was skipping the handling of touch
and pen messages during a drag and drop operation, preventing the
generation of events that quick was expecting and triggering a crash
inside MouseArea.
Fixes: QTBUG-73120
Change-Id: I2921e38dd7e44846607e6c614d7393cfa5664c69
Reviewed-by: Friedemann Kleint <Friedemann.Kleint@qt.io>
If there is no surrounding text then we can save time by not sending an
event to delete it as there is nothing to be deleted. This prevents the
underlying widget from being confused as to where the cursor and anchor
is later on when entering in new text.
Fixes: QTBUG-65584
Change-Id: Ic6325c119327048dffd2baa68520871fb56370d5
Reviewed-by: BogDan Vatra <bogdan@kdab.com>
As the listview in an input dialog is only used for selecting the entry
in place of a combobox, then we should prevent the input method from
being enabled. This ensures that it does not show an invalid text
cursor on devices like iOS and Android.
Change-Id: Ifb854e509573ec2d63d4cbcfa61335ae5b251ab5
Reviewed-by: Richard Moe Gustavsen <richard.gustavsen@qt.io>
The test started to fail now also for latest Windows 10 Update
Restone 2. It's unclear why the test was succeeding before, since this
seems a generic Windows API issue.
Task-number: QTBUG-64985
Task-number: QTQAINFRA-2255
Change-Id: I804f6a61c63ea70157353d1aee9027d0735073ab
Reviewed-by: Edward Welbourne <edward.welbourne@qt.io>
Configure is unable to find header files that are located in
frameworks. Work around that by specifying "include" on "test" level
instead of "headers" on "corewlan" level.
This amends commit 10adbc4f0f.
Change-Id: I0650585eb9a4e881dc2e3733d8db40c6e50cf1f3
Fixes: QTBUG-72964
Reviewed-by: Lars Knoll <lars.knoll@qt.io>
Reviewed-by: Alexandru Croitor <alexandru.croitor@qt.io>
Add a note explaining that it should not be used in multi-monitor
environments.
Task-number: QTBUG-73232
Change-Id: I7b61cef74eac4082efe849b3d5bdbbe5f04fcdbb
Reviewed-by: Paul Wicking <paul.wicking@qt.io>
The flag causes issues with High DPI scaling (the OS maintains
the size in device pixels when moving across screens).
It does not really make a difference (apart from the resize handle
appearing) since the dialog uses QLayout::SetFixedSize.
Fixes: QTBUG-73232
Change-Id: Iad08427796890582ac05758678d24e3cd707e669
Reviewed-by: Andy Shaw <andy.shaw@qt.io>
This is similar to a change we approved recently in OpenSSL back-end.
Similar to OpenSSL, not setting the upper limit on protocols allowed
to negotiate/use, neatly ends up with the highest available, which
is ... TLS 1.2 at the moment, but will silently switch to 1.3 etc.
This was also recommended by Apple's engineer who closed a related
bug report with 'Won't do' - "do not limit the max, you'll always
have the real max supported'. Also, while at the moment we do
not allow QSsl::TlsV1_3 and QSsl::TlsV1_3OrLater, if we managed
to negotiate it - report it properly, not as 'Unknown'.
Task-number: QTBUG-67463
Change-Id: I3f46ea525f06edca03259123809f3b7b1191b1ee
Reviewed-by: Mårten Nordheim <marten.nordheim@qt.io>
Reviewed-by: Edward Welbourne <edward.welbourne@qt.io>
The code was still using QPalette::background. It's now using window.
Change-Id: I9a47018d559d638ff69b1e4b2d7e2335e04a2a3a
Reviewed-by: Tor Arne Vestbø <tor.arne.vestbo@qt.io>