[plasma/libkscreen] src/doctor: doctor: add missing break statements in showOutputs() switch cases

zhang shoucheng <[email protected]>
Newsgroups gmane.comp.kde.cvs
Message-ID <[email protected]>
Git commit 50b25288569709e5b303879c94caeb484fc33467 by zhang shoucheng.
Committed on 30/07/2026 at 09:17.
Pushed by vladz into branch 'master'.

doctor: add missing break statements in showOutputs() switch cases

Three switch cases were missing break statements:
- Output::VrrPolicy::Always
- Output::RgbRange::Limited
- Output::AutoRotatePolicy::Always

While these are currently harmless (each is the last case before the
closing brace), missing breaks cause -Wimplicit-fallthrough compiler
warnings and pose a maintenance risk if new code is added between
the case and the closing brace in the future.

M  +3    -0    src/doctor/doctor.cpp

https://invent.kde.org/plasma/libkscreen/-/commit/50b25288569709e5b303879c94caeb484fc33467

diff --git a/src/doctor/doctor.cpp b/src/doctor/doctor.cpp
index ce7c0513..752cebba 100644
--- a/src/doctor/doctor.cpp
+++ b/src/doctor/doctor.cpp
@@ -719,6 +719,7 @@ void Doctor::showOutputs() const
                 break;
             case Output::VrrPolicy::Always:
                 cout << cr << "Always" << endl;
+                break;
             }
         } else {
             cout << cr << "incapable" << endl;
@@ -734,6 +735,7 @@ void Doctor::showOutputs() const
                 break;
             case Output::RgbRange::Limited:
                 cout << cr << "Limited" << endl;
+                break;
             }
         } else {
             cout << cr << "unknown" << endl;
@@ -917,6 +919,7 @@ void Doctor::showOutputs() const
                 break;
             case Output::AutoRotatePolicy::Always:
                 cout << cr << "always" << endl;
+                break;
             }
         } else {
             cout << cr << "incapable" << endl;
lmpx.com only provides a reader for public news (NNTP) servers. It is not affiliated with the servers or forums shown here and is not responsible for the content of articles, which is written by their respective authors.