summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorThierry Bastian <thierry.bastian@nokia.com>2009-07-15 15:31:06 (GMT)
committerThierry Bastian <thierry.bastian@nokia.com>2009-07-15 15:31:33 (GMT)
commit31bed31d6d058a17d74de05a1653256decdfc735 (patch)
treea86dc5062f3c7ea5fba2273b8db20c5490025522
parente68aa748a35725e3a6028ebc75a8447eff0912cb (diff)
downloadQt-31bed31d6d058a17d74de05a1653256decdfc735.zip
Qt-31bed31d6d058a17d74de05a1653256decdfc735.tar.gz
Qt-31bed31d6d058a17d74de05a1653256decdfc735.tar.bz2
fix warnings with mingw
-rw-r--r--src/gui/kernel/qapplication_win.cpp2
-rw-r--r--src/gui/kernel/qwidget_win.cpp2
-rw-r--r--src/gui/painting/qregion_win.cpp2
-rw-r--r--src/gui/text/qfontdatabase_win.cpp2
4 files changed, 6 insertions, 2 deletions
diff --git a/src/gui/kernel/qapplication_win.cpp b/src/gui/kernel/qapplication_win.cpp
index 243e361..ed219cd 100644
--- a/src/gui/kernel/qapplication_win.cpp
+++ b/src/gui/kernel/qapplication_win.cpp
@@ -1009,6 +1009,8 @@ const QString qt_reg_winclass(QWidget *w) // register window class
#ifndef QT_NO_DEBUG
if (!atom)
qErrnoWarning("QApplication::regClass: Registering window class failed.");
+#else
+ Q_UNUSED(atom);
#endif
winclassNames()->insert(cname, 1);
diff --git a/src/gui/kernel/qwidget_win.cpp b/src/gui/kernel/qwidget_win.cpp
index dcf541c..46fa3be 100644
--- a/src/gui/kernel/qwidget_win.cpp
+++ b/src/gui/kernel/qwidget_win.cpp
@@ -264,7 +264,7 @@ void QWidgetPrivate::create_sys(WId window, bool initializeWindow, bool destroyO
HINSTANCE appinst = qWinAppInst();
HWND parentw, destroyw = 0;
- WId id;
+ WId id = 0;
QString windowClassName = qt_reg_winclass(q);
diff --git a/src/gui/painting/qregion_win.cpp b/src/gui/painting/qregion_win.cpp
index 873439e..249b1a6 100644
--- a/src/gui/painting/qregion_win.cpp
+++ b/src/gui/painting/qregion_win.cpp
@@ -59,7 +59,7 @@ HRGN qt_tryCreateRegion(QRegion::RegionType type, int left, int top, int right,
{
const int tries = 10;
for (int i = 0; i < tries; ++i) {
- HRGN region;
+ HRGN region = 0;
switch (type) {
case QRegion::Rectangle:
region = CreateRectRgn(left, top, right, bottom);
diff --git a/src/gui/text/qfontdatabase_win.cpp b/src/gui/text/qfontdatabase_win.cpp
index 2e8e5e4..974b955 100644
--- a/src/gui/text/qfontdatabase_win.cpp
+++ b/src/gui/text/qfontdatabase_win.cpp
@@ -1026,6 +1026,8 @@ static void getFamiliesAndSignatures(const QByteArray &fontData, QFontDatabasePr
signature.fsCsb[0] = qFromBigEndian<quint32>(table + 78);
signature.fsCsb[1] = qFromBigEndian<quint32>(table + 82);
+ } else {
+ memset(&signature, 0, sizeof(signature));
}
appFont->signatures << signature;
}