summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
-rw-r--r--src/gui/painting/qtriangulatingstroker.cpp2
-rw-r--r--src/plugins/platforms/xcb/qxcbconnection.cpp2
-rw-r--r--src/widgets/kernel/qapplication.cpp4
3 files changed, 4 insertions, 4 deletions
diff --git a/src/gui/painting/qtriangulatingstroker.cpp b/src/gui/painting/qtriangulatingstroker.cpp
index d9a3231165..6243f1e2a4 100644
--- a/src/gui/painting/qtriangulatingstroker.cpp
+++ b/src/gui/painting/qtriangulatingstroker.cpp
@@ -321,7 +321,7 @@ void QTriangulatingStroker::cubicTo(const qreal *pts)
if (threshold < 4)
threshold = 4;
qreal threshold_minus_1 = threshold - 1;
- float vx, vy;
+ float vx = 0, vy = 0;
float cx = m_cx, cy = m_cy;
float x, y;
diff --git a/src/plugins/platforms/xcb/qxcbconnection.cpp b/src/plugins/platforms/xcb/qxcbconnection.cpp
index 9e275efa25..1af2cf9b89 100644
--- a/src/plugins/platforms/xcb/qxcbconnection.cpp
+++ b/src/plugins/platforms/xcb/qxcbconnection.cpp
@@ -417,7 +417,7 @@ void QXcbConnection::initializeScreens()
qWarning("failed to get the current screen resources");
free(error);
} else {
- xcb_timestamp_t timestamp;
+ xcb_timestamp_t timestamp = 0;
xcb_randr_output_t *outputs = Q_NULLPTR;
int outputCount = xcb_randr_get_screen_resources_current_outputs_length(resources_current.data());
if (outputCount) {
diff --git a/src/widgets/kernel/qapplication.cpp b/src/widgets/kernel/qapplication.cpp
index 358838b4e9..128b5dc2b8 100644
--- a/src/widgets/kernel/qapplication.cpp
+++ b/src/widgets/kernel/qapplication.cpp
@@ -3305,7 +3305,7 @@ bool QApplication::notify(QObject *receiver, QEvent *e)
QWheelEvent we(relpos, wheel->globalPos(), wheel->pixelDelta(), wheel->angleDelta(), wheel->delta(), wheel->orientation(), wheel->buttons(),
wheel->modifiers(), phase, wheel->source(), wheel->inverted());
bool eventAccepted;
- while (w) {
+ do {
we.spont = spontaneous && w == receiver;
we.ignore();
res = d->notify_helper(w, &we);
@@ -3323,7 +3323,7 @@ bool QApplication::notify(QObject *receiver, QEvent *e)
we.p += w->pos();
w = w->parentWidget();
- }
+ } while (w);
wheel->setAccepted(eventAccepted);
} else if (!spontaneous) {
// wheel_widget may forward the wheel event to a delegate widget,