Make it possible to identify its warnings in log files, like:
qdbusxml2cpp: Got unknown type `(s)' processing '../org.qtproject.QtDBus.Pinger.xml'
You should add <annotation name="org.qtproject.QtDBus.QtTypeName.Out0" value="<type>"/> to the XML description
qdbusxml2cpp: Got unknown type `(s)' processing '../org.qtproject.QtDBus.Pinger.xml'
You should add <annotation name="org.qtproject.QtDBus.QtTypeName.Out0" value="<type>"/> to the XML description
Change-Id: I242d9316b317de0164af2725b7836551f2f69037
Reviewed-by: Rolf Eike Beer <eb@emlix.com>
Reviewed-by: Thiago Macieira <thiago.macieira@intel.com>
Compare to QLatin1String and use reinterpret_cast to fix MSVC warning:
tst_qstring.cpp(1271): warning C4312: 'type cast': conversion from 'unsigned int' to 'void *' of greater size
Change-Id: I4f26d72f0fad59e09636fe609a2772309a688e5c
Reviewed-by: Marc Mutz <marc.mutz@kdab.com>
Add parentheses after function names, replace
is different -> differs
Change-Id: I6332db1d1650ed8d8320c5f20cd79d0bf1870e27
Reviewed-by: Mitch Curtis <mitch.curtis@qt.io>
As _BitScanForward and friends are not marked constexpr in Visual Studio,
functions using these may not be marked either.
Task-number: QTBUG-57086
Change-Id: I29cfa4459580b5740f1011e7f39309844518ce03
Reviewed-by: Thiago Macieira <thiago.macieira@intel.com>
Reviewed-by: Erik Verbruggen <erik.verbruggen@qt.io>
../tst_qfile.cpp: In member function 'void tst_QFile::handle()':
../tst_qfile.cpp:2661:38: warning: ignoring return value of 'ssize_t read(int, void*, size_t)', declared with attribute warn_unused_result [-Wunused-result]
tst_qstatictext.cpp:862:58: warning: unused parameter 'textItem' [-Wunused-parameter]
../tst_qtcpsocket.cpp: In member function 'void tst_QTcpSocket::abortiveClose()':
../tst_qtcpsocket.cpp:2254:90: warning: suggest parentheses around assignment used as truth value [-Wparentheses]
Test.cpp: In member function 'void My4Socket::read()':
Test.cpp:66:20: warning: 'reply' may be used uninitialized in this function [-Wmaybe-uninitialized]
../tst_qlocalsocket.cpp: In lambda function:
../tst_qlocalsocket.cpp:701:51: warning: comparison between signed and unsigned integer expressions [-Wsign-compare]
../tst_qtcpserver.cpp: In member function 'void tst_QTcpServer::linkLocal()':
../tst_qtcpserver.cpp:935:92: warning: suggest parentheses around assignment used as truth value [-Wparentheses]
../tst_qtcpserver.cpp:940:92: warning: suggest parentheses around assignment used as truth value [-Wparentheses]
Change-Id: Ic315069768bcb63a6b333c28ac65b0b992b0d43f
Reviewed-by: Jędrzej Nowacki <jedrzej.nowacki@qt.io>
Code generated by moc very often calls deprecated functions, like
deprecated slots, signals and property getters and setters. There's no
way around that unless the class in question is willing to break binary
compatibility, so those warnings are actually harmless.
Change-Id: Iaeecaffe26af4535b416fffd1489d1a98ef8b34a
Reviewed-by: Olivier Goffart (Woboq GmbH) <ogoffart@woboq.com>
This is the only warning we disable in a lot of places in Qt 5.8 source
code. If other warnings become common, we can add macros for them too.
Change-Id: Iaeecaffe26af4535b416fffd1489d1968e29c52a
Reviewed-by: Oswald Buddenhagen <oswald.buddenhagen@qt.io>
Reviewed-by: Olivier Goffart (Woboq GmbH) <ogoffart@woboq.com>
The user can call qSetMessagePattern after program start, so we need to
be sure that the parsed argument data is properly cleared.
Task-number: QTBUG-57144
Change-Id: I1978c6b95bd84639a8c4fffd1487429b04725522
Reviewed-by: Kai Koehne <kai.koehne@qt.io>
excise knowledge of QTREPOS from qt.prf - this is a private variable of
the qt build system which the public functions should not know anything
about.
instead, move this handling to a function in qt_build_config.prf (where
QTREPOS comes from in the first place), and call it from qt_app.prf and
qt_example_installs.prf (which should be the only consumers within qt).
qt.prf now also checks that the qml install dir actually exists, which
is not the case during a modular prefix build of qtdeclarative.
not really incidentally, this fixes modular static builds of
qtdeclarative.
Task-number: QTBUG-57308
Change-Id: I31465b9cd400483264fc236934c6f9f26a5fdd73
Reviewed-by: Simon Hausmann <simon.hausmann@qt.io>
we can't use $(QMAKE) after all, as this breaks with the visual studio
generator. so massage $$QMAKE_QMAKE into the final form manually
instead.
supersedes 591d9588f in amending 2b6bcd5ff.
Change-Id: I8c7a6c43f9668d88c1cc968dbf5614240f16239a
Reviewed-by: Joerg Bornemann <joerg.bornemann@qt.io>
Fix warning about unused variable printer in auto-test and redirects
output to qInfo() as intended.
Amends change a26435d65c.
Change-Id: Ia72a93267a54b9c4f9ef37fa058b95ef586ecc75
Reviewed-by: Simon Hausmann <simon.hausmann@qt.io>
Each supported version control system is described in
more detail in a dedicated topic since version 4.2.
Change-Id: I666f8c18d31954935c836509e572a3bfd2c2a32e
Reviewed-by: Venugopal Shivashankar <Venugopal.Shivashankar@qt.io>
Qt5Config restricts search paths of Qt components to ${_qt5_install_prefix}
to prevent accidentally using system Qt modules in case of restricted Qt
configuration. However this does not work properly when Qt is used without
installation, in particular when building cmake-based QtWebKit as a Qt
submodule, because ${_qt5_install_prefix} resolves to QtBase and does not
contain components from other modules.
This patch changes search path from ${_qt5_install_prefix} to all qt5
subdirectories.
Change-Id: Icf01a256097710889573ad69d847b9c3bffa1449
Reviewed-by: Kevin Funk <kevin.funk@kdab.com>
Reviewed-by: Oswald Buddenhagen <oswald.buddenhagen@qt.io>
gcc-base-unix.conf must be included before clang.conf because
clang.conf doesn't set all the needed flags.
Change-Id: I71f95732d0d245096b575c91610800d91c6aa5d7
Reviewed-by: Vyacheslav Koscheev <vok1980@gmail.com>
Reviewed-by: Oswald Buddenhagen <oswald.buddenhagen@qt.io>
They should be enabled/disabled through the configuration system.
Remove some unused defines, and move one define from qglobal.h to
a proper feature definition in Qt Gui.
Change-Id: Ie8d5bff9712ba745af60b42ceca3f0440bed2706
Reviewed-by: Thiago Macieira <thiago.macieira@intel.com>
Short-cut the case-insensitive string comparison when lengths doesn't
match.
This reduces the time spend in ucstricmp from 8% during start-up of the
textedit example, to under 1%.
Change-Id: Ib3a92900b330453289ec9eff4830dfac6a9a5da2
Reviewed-by: Thiago Macieira <thiago.macieira@intel.com>
Instead of doing the conversion from the big-endian data by hand, let's
use the convenience functions from qendian.h.
Change-Id: If3966ca94428afabb1f5c922967fb9970f976622
Reviewed-by: hjk <hjk@qt.io>
Shuffled its parts to make clear which bits are public, private and
protected. QDateTimeEditPrivate makes rather heavy use of the last.
Change-Id: Ic5f9d0c5cc85f02e57d3f31e9ac31a17428c5311
Reviewed-by: Timur Pocheptsov <timur.pocheptsov@qt.io>
If it fails, we get NULL back but haven't free()d the old pointer;
saving the NULL return over the old pointer forgets it, leaking the
memory it pointed to. This is particularly severe in the JSON
parser's grow(), where reading a very large JSON document can lead to
the last successful realloc() in a doubling pattern being very large
indeed; the subsequent failure will leak this very last allocation.
Only worth checking for, however, when the subsequent code takes care
to handle failure: in most cases, if realloc() fails, we're about to
crash anyway.
Change-Id: Icd3a503f169be224f0a058c58e8b7c82a3241ae7
Reviewed-by: Marc Mutz <marc.mutz@kdab.com>
Reviewed-by: Anton Kudryavtsev <antkudr@mail.ru>
Text that should simply have been naming days of the week used
Qt::Sunday rather than the simple day name.
Change-Id: I64a3cdacd854c1c9c0fbf2d11826555086d674f4
Reviewed-by: Thiago Macieira <thiago.macieira@intel.com>
We have:
...
auto networkSession = getNetworkSession();
...
getNetworkSession() can return non-null pointer even if
networkSessionStrongRef is null:
...
if (networkSessionStrongRef)
return networkSessionStrongRef;
return networkSessionWeakRef.toStrongRef();
....
We check the result:
if (networkSession) {
// here we disconnect signals
}
But we should use the same networkSession when disconnecting,
not start using networkSessionStrongRef suddenly, since it can
be null.
Task-number: QTBUG-57110
Change-Id: I96babb42c2182e741e6eabaf7d1abb88869861f4
Reviewed-by: Jesus Fernandez <jesus.fernandez@qt.io>
Reviewed-by: Edward Welbourne <edward.welbourne@qt.io>
Reviewed-by: Timur Pocheptsov <timur.pocheptsov@qt.io>
This is a backport of 6cc02ce6c8 from 5.7.
In a parallel build we may end up copying the qmldir file at the same
time, which doesn't work on Windows due to file locking. Apply the same
guard for the copying condition as in commit
770a0c91f3.
Task-number: QTBUG-57153
Change-Id: Ibac759b16cebaf04f5d2f785211b62071aa656a8
Reviewed-by: Oswald Buddenhagen <oswald.buddenhagen@qt.io>
of course, we should stub out everything related to TARGET - only the
generic "all" and "first" targets including their deps should be
emitted.
amends af2847260.
Change-Id: I8ed7a550b8022c69328d2e16dbd078928d176964
Reviewed-by: Joerg Bornemann <joerg.bornemann@qt.io>
actually pack the extra compilers' input files, not the variable names.
unlike on unix, we don't create an actual distdir, so the package is
still going to be rather broken.
Change-Id: If0a15bbe9db95aebd88c2a21ca3c0f787ce5c7e1
Reviewed-by: Joerg Bornemann <joerg.bornemann@qt.io>
SHGetSpecialFolderPath is declared 'unsupported' by Microsoft, and has
problems with non-ASCII characters. Replace it by the newer
SHGetKnownFolderPath.
Task-number: QTBUG-50570
Change-Id: I8b2dfa10fa5dc30e6c3be094a2ba8d7c3504f2ca
GPush-Base: 4d181bd93234a3747b520d10417825a0147bfeb1
Reviewed-by: Jan Arve Sæther <jan-arve.saether@qt.io>
Sending key events in addition causes applications to respond
twice to for example the back / forward extra mouse buttons.
Suppress the keypress by checking on the device. This is in
line with the other platforms, which do not send keypresses
either.
Native event filters will still be able to listen for
WM_APPCOMMAND.
Task-number: QTBUG-48117
Task-number: QTBUG-57198
Change-Id: I219e17244087663f06ab2c5a8cf4b880c3655700
Reviewed-by: Andy Shaw <andy.shaw@qt.io>
qdrawhelper.cpp is now compiled without PCH, and changes
blocked by the ICE can be reinstated.
This reverts commit cd9de59177.
Task-number: QTBUG-56817
Change-Id: I8d674768d16b3705598bfe5d08ed98376c97a478
Reviewed-by: Simon Hausmann <simon.hausmann@qt.io>
The code is dead, as the codec is never used on macOS.
Change-Id: I86138f1c95e5564256b4d592f0044e83658def93
Reviewed-by: Morten Johan Sørvig <morten.sorvig@qt.io>
Reviewed-by: Oswald Buddenhagen <oswald.buddenhagen@qt.io>
Turn iconv off if ICU is being used (in line with codecs.pri)
and get rid of the DEFINES += GNU_LIBICONV in the pri file.
Change-Id: I6fbca975498adbb3e67f913ae9b1dd5cc53ee8da
Reviewed-by: Oswald Buddenhagen <oswald.buddenhagen@qt.io>