From 005b556489d77ef566dcffcce9d7b4a085dc3959 Mon Sep 17 00:00:00 2001 From: Alex Blasche Date: Wed, 15 Jan 2014 16:07:53 +0100 Subject: Attempt to fix flaky QNemaPositionInfoSource_Simulation test on Windows The failure was discovered by https://codereview.qt-project.org/#change,75481 We increase the timeout for the local tcp connection as the likely reason is an overworked CI system. In addition we add more verbose output to easy the failure detection in case this happens again. Change-Id: I44ee52fcb957dcaa5aca4a6932221a34ce3f2af7 Reviewed-by: Kai Koehne --- .../qnmeapositioninfosourceproxyfactory.cpp | 17 ++++++++++++----- 1 file changed, 12 insertions(+), 5 deletions(-) diff --git a/tests/auto/qnmeapositioninfosource/qnmeapositioninfosourceproxyfactory.cpp b/tests/auto/qnmeapositioninfosource/qnmeapositioninfosourceproxyfactory.cpp index be8dfa78..6bf85173 100644 --- a/tests/auto/qnmeapositioninfosource/qnmeapositioninfosourceproxyfactory.cpp +++ b/tests/auto/qnmeapositioninfosource/qnmeapositioninfosourceproxyfactory.cpp @@ -86,14 +86,21 @@ QNmeaPositionInfoSourceProxy *QNmeaPositionInfoSourceProxyFactory::createProxy(Q { QTcpSocket *client = new QTcpSocket; client->connectToHost(m_server->serverAddress(), m_server->serverPort()); - //qDebug() << "listening on" << m_server->serverAddress() << m_server->serverPort(); - bool b = m_server->waitForNewConnection(5000); - Q_ASSERT(b); + qDebug() << "listening on" << m_server->serverAddress() << m_server->serverPort(); + bool b = m_server->waitForNewConnection(15000); + if (!b) + qWarning() << "Server didin't receive new connection"; b = client->waitForConnected(); - Q_ASSERT(b); + if (!b) + qWarning() << "Client could not connect to server"; //QNmeaPositionInfoSource *source = new QNmeaPositionInfoSource(m_mode); - source->setDevice(m_server->nextPendingConnection()); + QIODevice *device = m_server->nextPendingConnection(); + if (!device) + qWarning() << "Missing pending connection. Test is going to fail."; + else + qWarning() << "Received pending connection:" << device << b; + source->setDevice(device); Q_ASSERT(source->device() != 0); QNmeaPositionInfoSourceProxy *proxy = new QNmeaPositionInfoSourceProxy(source, client); proxy->setParent(source); -- cgit v1.2.3 From 6e824063d00031f8d069e59e2087b155a89b7fe3 Mon Sep 17 00:00:00 2001 From: Alex Blasche Date: Wed, 15 Jan 2014 10:01:29 +0100 Subject: Remove byte order marker which causes problems with older compilers Task-number: QTBUG-36187 Change-Id: Ie20ec6e802f44a6fa6757b914289736c4421138b Reviewed-by: Lars Knoll --- dist/changes-5.2.1 | 4 ++++ src/plugins/position/positionpoll/qgeoareamonitor_polling.h | 2 +- 2 files changed, 5 insertions(+), 1 deletion(-) diff --git a/dist/changes-5.2.1 b/dist/changes-5.2.1 index 28ba3bca..a3e7058c 100644 --- a/dist/changes-5.2.1 +++ b/dist/changes-5.2.1 @@ -25,6 +25,10 @@ General Improvements - [QTBUG-34910] * Fix too long weather status string in weatherinfo example (UI change). + - [QTBUG-36187] + * Byte order marker removed from positionpoll plugin which caused compile + errors on some older compilers. + - Fix make install rules for all examples. - declarative_core unit test was fixed and re-enabled. diff --git a/src/plugins/position/positionpoll/qgeoareamonitor_polling.h b/src/plugins/position/positionpoll/qgeoareamonitor_polling.h index f25cd685..41e15d30 100644 --- a/src/plugins/position/positionpoll/qgeoareamonitor_polling.h +++ b/src/plugins/position/positionpoll/qgeoareamonitor_polling.h @@ -1,4 +1,4 @@ -/**************************************************************************** +/**************************************************************************** ** ** Copyright (C) 2013 Digia Plc and/or its subsidiary(-ies). ** Contact: http://www.qt-project.org/legal -- cgit v1.2.3