summaryrefslogtreecommitdiffstats
path: root/examples
diff options
context:
space:
mode:
authorSona Kurazyan <sona.kurazyan@qt.io>2021-02-16 15:18:07 +0100
committerSona Kurazyan <sona.kurazyan@qt.io>2021-02-22 20:53:31 +0100
commitf050979e3d71cbb72a3b4d75f5e9898d81806487 (patch)
tree4e1498751ed9f3e7b404263cb511ff0cfda0a86a /examples
parent98b3171bbee84323640be24da230cf1c9b7d5cce (diff)
Clean-up warnings
Fixed the following warnings: - empty expression statement has no effect; remove unnecessary ';' - use of old-style cast - zero as null pointer constant - other minor things Change-Id: Ia672f48d2aa87c59354fc93fd19862f1875e13db Reviewed-by: Brett Stottlemyer <bstottle@ford.com> Reviewed-by: MÃ¥rten Nordheim <marten.nordheim@qt.io>
Diffstat (limited to 'examples')
-rw-r--r--examples/remoteobjects/plugins/plugin.cpp6
-rw-r--r--examples/remoteobjects/server/main.cpp2
-rw-r--r--examples/remoteobjects/ssl/sslserver/main.cpp2
3 files changed, 5 insertions, 5 deletions
diff --git a/examples/remoteobjects/plugins/plugin.cpp b/examples/remoteobjects/plugins/plugin.cpp
index 5ee35af..bddab06 100644
--- a/examples/remoteobjects/plugins/plugin.cpp
+++ b/examples/remoteobjects/plugins/plugin.cpp
@@ -63,7 +63,7 @@
// that change on-the-minute yet efficiently sleep the rest
// of the time.
-QRemoteObjectNode m_client;
+static QRemoteObjectNode m_client;
class TimeModel : public QObject
{
@@ -122,8 +122,8 @@ class QExampleQmlPlugin : public QQmlExtensionPlugin
public:
void initializeEngine(QQmlEngine *engine, const char *uri) override
{
- Q_UNUSED(engine);
- Q_UNUSED(uri);
+ Q_UNUSED(engine)
+ Q_UNUSED(uri)
Q_ASSERT(uri == QLatin1String("TimeExample"));
engine->addImportPath(QStringLiteral("qrc:/qml"));
m_client.setRegistryUrl(QUrl(QStringLiteral("local:registry")));
diff --git a/examples/remoteobjects/server/main.cpp b/examples/remoteobjects/server/main.cpp
index 10816aa..7eaab06 100644
--- a/examples/remoteobjects/server/main.cpp
+++ b/examples/remoteobjects/server/main.cpp
@@ -99,6 +99,6 @@ int main(int argc, char *argv[])
MinuteTimer timer;
node2.enableRemoting(&timer);
- Q_UNUSED(timer);
+ Q_UNUSED(timer)
return app.exec();
}
diff --git a/examples/remoteobjects/ssl/sslserver/main.cpp b/examples/remoteobjects/ssl/sslserver/main.cpp
index 6c7b8d6..73ec70e 100644
--- a/examples/remoteobjects/ssl/sslserver/main.cpp
+++ b/examples/remoteobjects/ssl/sslserver/main.cpp
@@ -135,7 +135,7 @@ int main(int argc, char *argv[])
MinuteTimer timer;
host.enableRemoting(&timer);
- Q_UNUSED(timer);
+ Q_UNUSED(timer)
return app.exec();
}