From 7003d80173c14747aac9eda6c5e270d47578460f Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Martin=20Gr=C3=A4=C3=9Flin?= Date: Wed, 3 Sep 2014 20:04:31 +0200 Subject: [PATCH] [kwin_wayland] Add assert in Display::setRunning Making the impossible condition an assert instead of a return. --- src/wayland/display.cpp | 4 +--- 1 file changed, 1 insertion(+), 3 deletions(-) diff --git a/src/wayland/display.cpp b/src/wayland/display.cpp index 46394f417a..3fef02c0c1 100644 --- a/src/wayland/display.cpp +++ b/src/wayland/display.cpp @@ -110,9 +110,7 @@ void Display::terminate() void Display::setRunning(bool running) { - if (m_running == running) { - return; - } + Q_ASSERT(m_running != running); m_running = running; emit runningChanged(m_running); }