Since some databases are case sensitive if part of the query is quoted,
then we should ensure that all instances of the table name are escaped
unless the test is delibrately testing the non-escaped case.
As a result, this commit also removes some expected failures pertaining
to PostgreSQL and also adds an entry to the list of tables being dropped
when a test is finished.
[ChangeLog][Sql][PostgreSQL] QSqlDatabase is now stricter about table
names when used with record() and primaryIndex(). If the tablename was
not quoted when it was created, then the table name passed to record()
and primaryIndex() needs to be in lower case so that PostgreSQL is
able to find it.
Fixes: QTBUG-65788
Change-Id: Id1f54cb66b761c39edf858501b730ede7eec1fd3
Reviewed-by: Paul Wicking <paul.wicking@qt.io>
Reviewed-by: Edward Welbourne <edward.welbourne@qt.io>
QFile/QFileInfo::readLink() functions are obsolete but were not marked
as deprecated.
Explicit mark them as deprecated so they can be removed with Qt6.
Change-Id: I52424dc5441e1f5b01015713df990bbec5186caa
Reviewed-by: Thiago Macieira <thiago.macieira@intel.com>
Reviewed-by: Friedemann Kleint <Friedemann.Kleint@qt.io>
Reviewed-by: Jędrzej Nowacki <jedrzej.nowacki@qt.io>
QProcess::finished(int)/readChannelMode()/setReadChannelMode() are
obsolete but were not marked as deprecated.
Explicit mark them as deprecated so they can be removed with Qt6.
Change-Id: Iedbfd80a3c987f35caf93181e9277913a18961d9
Reviewed-by: Thiago Macieira <thiago.macieira@intel.com>
Reviewed-by: Mårten Nordheim <marten.nordheim@qt.io>
QDrag::start() is deprecated since Qt4. Therefore annotate it with
Q_DEPRECATED so it can be removed in Qt6.
Change-Id: I5b82c482fa579f357cc67e38b86e6fe587f18ded
Reviewed-by: André Hartmann <aha_1980@gmx.de>
Reviewed-by: Friedemann Kleint <Friedemann.Kleint@qt.io>
Reviewed-by: Richard Moe Gustavsen <richard.gustavsen@qt.io>
Cleanup the Widgets examples - replace foreach with range-based for loop
in the remaining directories
Change-Id: I321e6c0f414401a1ae4fb65762b97d894b725afa
Reviewed-by: Paul Wicking <paul.wicking@qt.io>
Reviewed-by: Luca Beldi <v.ronin@yahoo.it>
Cleanup the Widgets examples - replace foreach with range-based for loop
in graphicsview subdirectory
Change-Id: I9093b3ae89d73d0b860d29929943881c90074bce
Reviewed-by: Luca Beldi <v.ronin@yahoo.it>
Reviewed-by: Paul Wicking <paul.wicking@qt.io>
Cleanup the Widgets examples - replace foreach with range-based for loop
in mainwindows and painting subdirectories
Change-Id: I3c1556dffd22e29dd0a5ba960e699291c496278a
Reviewed-by: Konstantin Shegunov <kshegunov@gmail.com>
Reviewed-by: Paul Wicking <paul.wicking@qt.io>
Reviewed-by: Luca Beldi <v.ronin@yahoo.it>
Reviewed-by: Martin Smith <martin.smith@qt.io>
Mark the following obsolete functions as deprecated so they can be
removed with Qt6:
- QDataStream::unsetDevice()
- QDir &QDir::operator=(const QString &path)
- QDir::addResourceSearchPath()
- QResource::addSearchPath()
- QResource::searchPaths()
- QSettings::setSystemIniPath()
- QSettings::setUserIniPath()
Change-Id: I5edfb2b4ce1ad843fa5fcd5b4c475ab9352b05f7
Reviewed-by: Thiago Macieira <thiago.macieira@intel.com>
Instead of stepping down to 4 pixels, then 2 px, then 1, with
essentially the same code, let's use maskload and maskstore to only load
and store the effective portions (instructions new in AVX2). The
secondary loop gets run at most twice, since there can be at most 7
pixels left.
This fixes an off-by-4 bug in the previous implementation (lines 1041
and 1186 should have had 7 instead of 3).
Change-Id: I4d4dadb709f1482fa8ccfffd157862e77ac508f6
Reviewed-by: Allan Sandfeld Jensen <allan.jensen@qt.io>
Change b86d0b6215 rearranged the
sequence of function calls when generating code adding QTabWidget
and QToolBox pages, not taking into account that the iconCall()
has a side effect (writing out icon definition) Revert that part
and add a comment.
Fixes: QTBUG-72980
Task-number: PYSIDE-797
Change-Id: Ie8fbaa36f21cd4408fb1f491195da5c260708e6c
Reviewed-by: Jarek Kobus <jaroslaw.kobus@qt.io>
about why a certificate was revoked (if it was) and the responder's
certificate, if we managed to verify a signature, as was previously
shortly discussed in the 'OCSP stapling' patch-set. Auto-test update
will be in a separate patch.
[ChangeLog][QtNetwork][Ssl] Added class QOcspResponse as a part of
OCSP stapling support.
Change-Id: I4e17fb6fc4c3dae0b8ad04ff2897a4823736d16e
Reviewed-by: Mårten Nordheim <marten.nordheim@qt.io>
Reviewed-by: Timur Pocheptsov <timur.pocheptsov@qt.io>
Useful in contexts such as other QDebug operators, where the class
is already known, and the full scope of the flags is not needed.
Change-Id: I546381b1722c9c846e2412e56763563b8f625212
Reviewed-by: Thiago Macieira <thiago.macieira@intel.com>
Useful in contexts such as other QDebug operators, where the class
is already known, and the full scope of the enum is not needed.
Change-Id: Ibd04b1fd4f0f914c7224a007fc248d4ebabcde3e
Reviewed-by: Thiago Macieira <thiago.macieira@intel.com>
Setting the fall-back network interface of danted's environment to eth0
by docker-compose file is redundant because the value of danted's
configuration (danted.conf) has been set to eth0 by default.
Change-Id: If2dea8daaf851577a573e201e9c50684916e5206
Reviewed-by: Edward Welbourne <edward.welbourne@qt.io>
Reviewed-by: Jędrzej Nowacki <jedrzej.nowacki@qt.io>
For macOS and Windows, the test-server containers are deployed in the
VirtualBox (Boot2Docker). Because Boot2Docker is a lightweight Linux
distribution made specifically to run Docker containers, it doesn't
install avahi-daemon and support mDNS discovery.
To resolve this problem, Docker compose file supports "extra_hosts" to
add hostname mappings inside containers.
BFAIL items:
tst_QNetworkReply::headFromHttp(...+proxy...) (ten cases)
tst_QNetworkReply::ioGetWithManyProxies(http-on-http)
tst_QNetworkReply::ioGetWithManyProxies(http-on-http2)
tst_QNetworkReply::ioGetWithManyProxies(http-on-multiple-http)
tst_QNetworkReply::ioGetWithManyProxies(http-on-http+socks)
tst_QNetworkReply::ioGetWithManyProxies(http-on-ftp+http+socks)
tst_QNetworkReply::ioPostToHttpFromSocket(...+proxy) (twelve cases)
tst_QNetworkReply::ioPostToHttpFromSocket(...+proxyauth) (ten cases)
Change-Id: Iec55966a9b5f191b7446985a15b49a8b09dcf407
Reviewed-by: Jędrzej Nowacki <jedrzej.nowacki@qt.io>
Docker compose file supports variable substitution. When running
docker-compose up, Compose looks for the environment variables from
shell and substitutes the values at runtime.
Change-Id: I5255ead82276fac7db24ee74af453f83ca20bbe6
Reviewed-by: Jędrzej Nowacki <jedrzej.nowacki@qt.io>
Reviewed-by: Edward Welbourne <edward.welbourne@qt.io>
There is no docker bridge on Windows. Docker document recommends using
port mapping to connect to a container. The problem is that it causes a
port conflict if the user is running a service that binds the same port
on the host. This change applies the same solution of macOS to deploy
the docker environment into VirtualBox and use the host network option.
Task-number: QTQAINFRA-2294
Change-Id: Iedcb8daa39373f02adb59f02eae2775f02870c54
Reviewed-by: Jędrzej Nowacki <jedrzej.nowacki@qt.io>
Reviewed-by: Edward Welbourne <edward.welbourne@qt.io>
Apparently, it is not enough to just retry 10 times (10 seconds) in the
CI network. It happens from time to time that a test fails due to server
port is unreachable. Especially, the docker containers are running in a
virtual machine on Windows and macOS platforms. In such cases, it needs
more time to warm up the service depending on the system loading.
Change-Id: Ia0234bff2a82988b62f451e20b50671708784008
Reviewed-by: Edward Welbourne <edward.welbourne@qt.io>
Reviewed-by: Jędrzej Nowacki <jedrzej.nowacki@qt.io>
With the current distribution, this is 90% of active devices, and
it was released in 2014. Qt 5.12 is LTS and will continue to support
older Android versions for a long time to come.
This is to reduce the testing needed on outdated platforms and
allow ourselves to use some newer APIs unconditionally in Qt.
Android 21 was chosen because it is the minimum version that supports
64 bit builds.
[ChangeLog][Android] Increased the minimum supported Android version
to Android 5.0 (API level 21).
Fixes: QTBUG-70508
Change-Id: Ia7b4345e42ca05a25a292f11ccbb8cbd692cf8f0
Reviewed-by: BogDan Vatra <bogdan@kdab.com>
Cleanup the widgets examples - replace 0 with nullptr
Change-Id: Id4bf119b9a41f6d10117f3a613a6e604128fa196
Reviewed-by: Konstantin Shegunov <kshegunov@gmail.com>
Reviewed-by: Edward Welbourne <edward.welbourne@qt.io>
Reviewed-by: Paul Wicking <paul.wicking@qt.io>
Adds support for Schannel, an SSL backend for Windows, as an
alternative to OpenSSL.
[ChangeLog][QtNetwork][Ssl] Added support for Schannel on Desktop
Windows. To build Qt with Schannel support use '-schannel' during
configure.
Task-number: QTBUG-62637
Change-Id: Ic4fb8ed3657dab994f9f4a4ac5cbddc7001a0a46
Reviewed-by: Timur Pocheptsov <timur.pocheptsov@qt.io>
Some of the spdy/3 tests don't pass anymore because those services
no longer support spdy/3. Solve this by updating it to HTTP/2 (h2).
Change-Id: Ib3ef6109b75f4298fed15c1c7922deca35459df9
Reviewed-by: Timur Pocheptsov <timur.pocheptsov@qt.io>
Reviewed-by: Edward Welbourne <edward.welbourne@qt.io>
Make it more like feature 'dtls' test.
Change-Id: I29f5e9337d99440015431a8cfb001f5fb28e1c5f
Reviewed-by: Mårten Nordheim <marten.nordheim@qt.io>
Reviewed-by: Edward Welbourne <edward.welbourne@qt.io>
The CreationDate entry in the two PDF files can potentially
be different depending on when the test is run.
97b4c5a574 already accounts for it but
the current tag for creation date is '/CreationDate'. Therefore check
if the line contains 'CreationDate' instead.
Change-Id: I1fc069cf935bba07084ac4a0743ff05312374d10
Reviewed-by: Thiago Macieira <thiago.macieira@intel.com>
tst_QString::localeAwareCompare() is failing since
ab448f731e because the 'C' locale no
longer initializes ICU and falls back to simple QString comparison.
Fix it by explicitly setting the locale for the testdata to en_US so the
QCollator is properly initialized.
Task-number: QTBUG-73116
Change-Id: I9d4d55e666c5c52f93298dedb7e22da01a25318d
Reviewed-by: Thiago Macieira <thiago.macieira@intel.com>
QSqlRelationalDelegate::setEditorData() does not compile when
QT_NO_CAST_FROM_BYTEARRAY is defined. Since it's a public header this
will break user code.
Fix it by calling QByteArray::data() instead of relying on the
implicit cast.
Fixes: QTBUG-72764
Change-Id: I9c111dd25f48c9c9780d9f9a5b6b75eed0c8d6ed
Reviewed-by: Edward Welbourne <edward.welbourne@qt.io>
Reviewed-by: Andy Shaw <andy.shaw@qt.io>
The output files for the tuplediagnostics selftest of testlib had a
stray non-canoical path fragment in them; so replaced with its
canonical form.
Change-Id: Ib421380036c3fb1b91447eb8c87be4ad0dfe5c96
Reviewed-by: Jędrzej Nowacki <jedrzej.nowacki@qt.io>
This appears to be a timing issue of vsftpd's initial script
(/etc/init.d/vsftpd). When starting the vsftpd service, the script uses
a while loop to make sure that the vsftpd process has been created with
the expected PID. The problem is that it should sleep if it can't grep
the same PID via ps command.
while [ ${n} -le 5 ]
do
_PID="$(if [ -e ...vsftpd.pid ]; then cat ...vsftpd.pid; fi)"
if ! ps -C vsftpd | grep -qs "${_PID}"
then
break
fi
sleep 1
n=$(( $n + 1 ))
done
if ! ps -C vsftpd | grep -qs "${_PID}"
then
log_warning_msg "vsftpd failed - probably invalid config."
exit 1
fi
However, synchronization based on time is not working in general. This
change will rewrite the while loop to an infinite loop and remove the
exclamation symbol (!) from the if condition.
Upgrading the version of vsftpd is not helpful here because
vsftpd_3.0.3-11 (Ubuntu 18.10) didn't resolve it yet.
Change-Id: I07382709c33bd9bab61fcea76ab7deca5f630084
Reviewed-by: Jędrzej Nowacki <jedrzej.nowacki@qt.io>
Reviewed-by: Edward Welbourne <edward.welbourne@qt.io>
The remaining diff to clean 1.6.36 is archived in the qtpatches.diff file.
[ChangeLog][Third-Party Code] libpng was updated to version 1.6.36
Change-Id: Ia9d20c5abca115d509ed0aaf9eebfc85a88bef1d
Reviewed-by: Kai Koehne <kai.koehne@qt.io>
Reviewed-by: Eirik Aavitsland <eirik.aavitsland@qt.io>
The bool is assigned on the previous line: QTRY_VERIFY will not do
anything because the statement is already true.
Change-Id: I067290e19ffd100819b2b631af431c6013623a00
Reviewed-by: Jędrzej Nowacki <jedrzej.nowacki@qt.io>
It was an implicit effect before which stopped working after
dec7961709. Reintroduce it as some
projects used this side-effect as a way to abort the initial
highlighting.
Change-Id: I5340ee9882a242bc8b5f7f843f1cfe793a65d357
Reviewed-by: Jędrzej Nowacki <jedrzej.nowacki@qt.io>
There are certain use cases for keeping debug information on the
device, for example collecting stack traces when the app crashes.
[ChangeLog][Android] Added the --no-strip command line option to
androiddeployqt.
Change-Id: I96574c2c57d85fb23d5fc65380e471fa892b6543
Fixes: QTBUG-57771
Reviewed-by: Volker Krause <volker.krause@kdab.com>
Reviewed-by: Andy Shaw <andy.shaw@qt.io>
Run the handling in QWindowPrivate::maybeQuitOnLastWindowClosed()
for top level windows only.
Fixes: QTBUG-73061
Change-Id: I74deb50b06a64e8ef0e438d2abf14888f778a46e
Reviewed-by: Tor Arne Vestbø <tor.arne.vestbo@qt.io>
Reviewed-by: Qt CI Bot <qt_ci_bot@qt-project.org>
We use NSButton to emulate tabs in QTabWidget. Starting from 10.14
in dark theme those button objects tend to be somewhat transparent,
thus widget's frame is visible through tab buttons. This is true for
native controls also - NSButton, NSSegmentedControl, NSTabView - they
all show the similar behavior. The only difference is NSTabView, which
is the closest control to our QTabWidget - tab buttons are transparent,
but they (AppKit) it would appear just do not draw the frame under
this area. Let's do the same, but using clipping.
Task-number: QTBUG-71741
Change-Id: I9f19014d0db5f36bacf76ee0068fae6eee793c0f
Reviewed-by: Tor Arne Vestbø <tor.arne.vestbo@qt.io>
When debug_and_release option is in use, qmake will generate one
mata-Makefile and two additional leaf Makefile (Makefile.Debug and
Makefile.Release). In such case, testserver.pri will be included in all
three passes. The problem is that the mata-Mafile is used to invoke leaf
Mafile recursively. The docker test server should only be integrated in
the leaf Makefile.
To resolve this problem, this change uses "!build_pass" condition to
determine whether this is a pass of meta-Makefile, and then skip it.
Change-Id: Ibc48d657680e089ebaa1bc356b87eb4cfd9f4580
Reviewed-by: Jędrzej Nowacki <jedrzej.nowacki@qt.io>
Reviewed-by: Edward Welbourne <edward.welbourne@qt.io>
Commit c8c5ff19de introduced the solution
as a simple scaling up of the code in qdrawhelper_sse4.cpp, but it's bad
due to the way that the 256-bit unpack instructions work: the unpack-low
instruction unpacks the lower half of each half of the 256-bit register.
So we fix it up by inserting a permute4x64 that swaps the middle two
quarters of the 256-bit register (permute8x32 requires a __m256i
parameter, instead of an immediate).
This introduces an instruction that costs 3 cycles in each loop, but
since the AVX2 code has double the throughput compared to SSE4 code, it
should still be faster.
This problem does not affect the ARGB->ARGB32 code because that repacks
at the end.
Change-Id: I4d4dadb709f1482fa8ccfffd1578620b45166a4f
Reviewed-by: Allan Sandfeld Jensen <allan.jensen@qt.io>
Per the Khronos documentation, this operation is not permitted on ES 3.
Change-Id: Iff70ef83d48228277b883df588011432ba80f4bd
Reviewed-by: Giuseppe D'Angelo <giuseppe.dangelo@kdab.com>
With all the headers missing, Creator's clang code model just gives up and
it's impossible to work on testlib in Creator.
Change-Id: I8814264db10992eeec6f45625580f6788d23b56b
Reviewed-by: Edward Welbourne <edward.welbourne@qt.io>
The @executable_path relative framework directory is one step below
the executable, as in:
Foo.app/Contents/Frameworks
not:
Foo.app/Contents/MacOS/Frameworks
The former is what Xcode defaults to for new projects.
Change-Id: Id08f3f1d80f1c84d76fb71676c5df4a3a6b3da36
Reviewed-by: Kai Koehne <kai.koehne@qt.io>
Reviewed-by: Joerg Bornemann <joerg.bornemann@qt.io>
Reviewed-by: Tor Arne Vestbø <tor.arne.vestbo@qt.io>
Q_DECLARE_PRIVATE gets used in the declaration of the public class,
where the private class is typically visible only as a forward-decl,
with no knowledge of what it's based on; consequently, the macro is
obliged to use reinterpret_cast<>, which is subject to warnings when
the compiler *can* see both types and their alignments differ. The
same applies to Q_DECLARE_PRIVATE_D.
So suppress gcc's -Wcast-align around the d_func() return statements.
(If we get similar problems with other compilers we can add their
suppressions likewise; but, for now, we've only seen this on MIPS64,
where we use gcc.) This tripped over one use of Q_DECLARE_PRIVATE in
a private Q_SLOTS: section; for some reason, gcc didn't like the
semicolon on the friend declaration. Changing the context to plain
private fixed that.
Fixes: QTBUG-72885
Change-Id: I5edc11d46bd4eb820713adede79d53191a7e2736
Reviewed-by: Liang Qi <liang.qi@qt.io>
Reviewed-by: Ville Voutilainen <ville.voutilainen@qt.io>
Reviewed-by: Boxiang Sun <daetalusun@gmail.com>
tr() recognizes %n and %Ln. it offers no way to escape lone percent
signs, which implies that they must be interpreted verbatim, which is
what the code actually does. except that it would run off the end if the
% appeared at the end of the string.
Fixes: QTBUG-57171
Done-with: Mateusz Starzycki <mstarzycki@gmail.com>
Change-Id: Icf81925c482be1ea66ec8daafb3e92ad17ea7fab
Reviewed-by: Oswald Buddenhagen <oswald.buddenhagen@gmx.de>