diff options
author | Friedemann Kleint <Friedemann.Kleint@nokia.com> | 2011-05-19 16:19:01 +0200 |
---|---|---|
committer | Friedemann Kleint <Friedemann.Kleint@nokia.com> | 2011-05-19 16:20:08 +0200 |
commit | 49995ee35ff0b26e32303d77df619d3a2fbcb86b (patch) | |
tree | 59cac159b76d07a407149870a9f469251d99ac5c /tests/benchmarks | |
parent | a98ebc599ab7c99a6431d0420d3f0d238f37f6b1 (diff) |
Tests: Fix some compile warnings.
As they are now compiled by default.
Diffstat (limited to 'tests/benchmarks')
4 files changed, 5 insertions, 2 deletions
diff --git a/tests/benchmarks/gui/painting/qpainter/tst_qpainter.cpp b/tests/benchmarks/gui/painting/qpainter/tst_qpainter.cpp index 2d33825e5c..895d7bff63 100644 --- a/tests/benchmarks/gui/painting/qpainter/tst_qpainter.cpp +++ b/tests/benchmarks/gui/painting/qpainter/tst_qpainter.cpp @@ -924,6 +924,7 @@ void tst_QPainter::fillPrimitives_helper(QPainter *p, PrimitiveType type, Primit case Primitive_Float_RectPath: QBENCHMARK { p->drawPath(s->f_path_rect); } break; case Primitive_Float_2RectPath: QBENCHMARK { p->drawPath(s->f_path_2rects); } break; case Primitive_Float_EllipsePath: QBENCHMARK { p->drawPath(s->f_path_ellipse); } break; + case Primitive_Last_Primitive: break; } } diff --git a/tests/benchmarks/gui/painting/qtracebench/tst_qtracebench.cpp b/tests/benchmarks/gui/painting/qtracebench/tst_qtracebench.cpp index e71cfc6413..58566fe6a2 100644 --- a/tests/benchmarks/gui/painting/qtracebench/tst_qtracebench.cpp +++ b/tests/benchmarks/gui/painting/qtracebench/tst_qtracebench.cpp @@ -149,7 +149,7 @@ void ReplayWidget::paintEvent(QPaintEvent *) } } -void ReplayWidget::resizeEvent(QResizeEvent *event) +void ReplayWidget::resizeEvent(QResizeEvent * /* event */) { visibleUpdates.clear(); diff --git a/tests/benchmarks/gui/text/qtext/main.cpp b/tests/benchmarks/gui/text/qtext/main.cpp index 01e8c46bd8..97abc93b44 100644 --- a/tests/benchmarks/gui/text/qtext/main.cpp +++ b/tests/benchmarks/gui/text/qtext/main.cpp @@ -411,6 +411,7 @@ void tst_QText::paintLayoutToPixmap_painterFill() void tst_QText::document() { QTextDocument *doc = new QTextDocument; + Q_UNUSED(doc) QBENCHMARK { QTextDocument *doc = new QTextDocument; @@ -453,6 +454,7 @@ void tst_QText::paintDocToPixmap_painterFill() void tst_QText::control() { QTextControl *control = new QTextControl(m_shortLorem); + Q_UNUSED(control); QBENCHMARK { QTextControl *control = new QTextControl; diff --git a/tests/benchmarks/network/access/qnetworkreply/tst_qnetworkreply.cpp b/tests/benchmarks/network/access/qnetworkreply/tst_qnetworkreply.cpp index 9a07aa4940..a96fa63b5a 100644 --- a/tests/benchmarks/network/access/qnetworkreply/tst_qnetworkreply.cpp +++ b/tests/benchmarks/network/access/qnetworkreply/tst_qnetworkreply.cpp @@ -501,7 +501,7 @@ void tst_qnetworkreply::echoPerformance() QByteArray data; data.resize(1024*1024*10); // 10 MB // init with garbage. needed so ssl cannot compress it in an efficient way. - for (int i = 0; i < data.size() / sizeof(int); i++) { + for (size_t i = 0; i < data.size() / sizeof(int); i++) { int r = qrand(); data.data()[i*sizeof(int)] = r; } |