From 9183a416c2e72e0a96c9f206b1bb2daae815875f Mon Sep 17 00:00:00 2001 From: Alessandro Portale Date: Fri, 21 Aug 2009 23:38:25 +0200 Subject: Fixed unreferenced variable warning in Release mode. --- src/gui/styles/qs60style.cpp | 3 +-- 1 file changed, 1 insertion(+), 2 deletions(-) diff --git a/src/gui/styles/qs60style.cpp b/src/gui/styles/qs60style.cpp index 2a88c9a..b05a1e9 100644 --- a/src/gui/styles/qs60style.cpp +++ b/src/gui/styles/qs60style.cpp @@ -426,13 +426,12 @@ QColor QS60StylePrivate::colorFromFrameGraphics(SkinFrameElements frame) const Q_ASSERT(2*frameCornerHeight<32); const QImage frameImage = QS60StylePrivate::frame(frame, QSize(32,32)).toImage(); + Q_ASSERT(frameImage.bytesPerLine() > 0); if (frameImage.isNull()) return Qt::black; const QRgb *pixelRgb = (const QRgb*)frameImage.bits(); const int pixels = frameImage.numBytes()/sizeof(QRgb); - const int bytesPerLine = frameImage.bytesPerLine(); - Q_ASSERT(bytesPerLine); int estimatedRed = 0; int estimatedGreen = 0; -- cgit v0.12