[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
[RFC PATCH 14/78] util/error-report.c: add fallthrough pseudo-keyword
From: |
Emmanouil Pitsidianakis |
Subject: |
[RFC PATCH 14/78] util/error-report.c: add fallthrough pseudo-keyword |
Date: |
Fri, 13 Oct 2023 10:47:18 +0300 |
In preparation of raising -Wimplicit-fallthrough to 5, replace all
fall-through comments with the fallthrough attribute pseudo-keyword.
Signed-off-by: Emmanouil Pitsidianakis <manos.pitsidianakis@linaro.org>
---
util/error-report.c | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/util/error-report.c b/util/error-report.c
index 6e44a55732..acb66420de 100644
--- a/util/error-report.c
+++ b/util/error-report.c
@@ -353,36 +353,36 @@ static char *qemu_glog_domains;
static void qemu_log_func(const gchar *log_domain,
GLogLevelFlags log_level,
const gchar *message,
gpointer user_data)
{
switch (log_level & G_LOG_LEVEL_MASK) {
case G_LOG_LEVEL_DEBUG:
case G_LOG_LEVEL_INFO:
/*
* Use same G_MESSAGES_DEBUG logic as glib to enable/disable debug
* messages
*/
if (qemu_glog_domains == NULL) {
break;
}
if (strcmp(qemu_glog_domains, "all") != 0 &&
(log_domain == NULL || !strstr(qemu_glog_domains, log_domain))) {
break;
}
- /* Fall through */
+ fallthrough;
case G_LOG_LEVEL_MESSAGE:
info_report("%s%s%s",
log_domain ?: "", log_domain ? ": " : "", message);
break;
case G_LOG_LEVEL_WARNING:
warn_report("%s%s%s",
log_domain ?: "", log_domain ? ": " : "", message);
break;
case G_LOG_LEVEL_CRITICAL:
case G_LOG_LEVEL_ERROR:
error_report("%s%s%s",
log_domain ?: "", log_domain ? ": " : "", message);
break;
}
}
--
2.39.2
- Re: [RFC PATCH 07/78] hw/virtio/virtio-balloon.c: add fallthrough pseudo-keyword, (continued)
- [RFC PATCH 08/78] hw/block: add fallthrough pseudo-keyword, Emmanouil Pitsidianakis, 2023/10/13
- [RFC PATCH 06/78] tcg: add fallthrough pseudo-keyword, Emmanouil Pitsidianakis, 2023/10/13
- [RFC PATCH 10/78] hw/ide/atapi.c: add fallthrough pseudo-keyword, Emmanouil Pitsidianakis, 2023/10/13
- [RFC PATCH 11/78] hw/timer: add fallthrough pseudo-keyword, Emmanouil Pitsidianakis, 2023/10/13
- [RFC PATCH 09/78] hw/acpi/aml-build.c: add fallthrough pseudo-keyword, Emmanouil Pitsidianakis, 2023/10/13
- [RFC PATCH 12/78] hw/usb: add fallthrough pseudo-keyword, Emmanouil Pitsidianakis, 2023/10/13
- [RFC PATCH 13/78] hw/adc: add fallthrough pseudo-keyword, Emmanouil Pitsidianakis, 2023/10/13
- [RFC PATCH 14/78] util/error-report.c: add fallthrough pseudo-keyword,
Emmanouil Pitsidianakis <=
- [RFC PATCH 15/78] accel/tcg: add fallthrough pseudo-keyword, Emmanouil Pitsidianakis, 2023/10/13
- [RFC PATCH 17/78] ui/sdl2.c: add fallthrough pseudo-keyword, Emmanouil Pitsidianakis, 2023/10/13
- [RFC PATCH 16/78] audio: add fallthrough pseudo-keyword, Emmanouil Pitsidianakis, 2023/10/13
- [RFC PATCH 19/78] target/hppa: add fallthrough pseudo-keyword, Emmanouil Pitsidianakis, 2023/10/13
- [RFC PATCH 18/78] ui/win32-kbd-hook.c: add fallthrough pseudo-keyword, Emmanouil Pitsidianakis, 2023/10/13
- [RFC PATCH 20/78] target/mips: add fallthrough pseudo-keyword, Emmanouil Pitsidianakis, 2023/10/13
- [RFC PATCH 22/78] target/ppc: add fallthrough pseudo-keyword, Emmanouil Pitsidianakis, 2023/10/13
- [RFC PATCH 21/78] target/sparc: add fallthrough pseudo-keyword, Emmanouil Pitsidianakis, 2023/10/13
- [RFC PATCH 27/78] target/riscv: add fallthrough pseudo-keyword, Emmanouil Pitsidianakis, 2023/10/13