From d49410d59985ce3666ac395eec92e86e5fd7e5e3 Mon Sep 17 00:00:00 2001 From: "Enrico Weigelt, metux IT consult" Date: Thu, 12 Sep 2024 17:39:33 +0200 Subject: [PATCH] (!1691) os: log: replace VErrorFSigSafe() by VErrorF() Since VErrorF() is now signal safe, we can use this one instead. Leaving VErrorFSigSafe() macro for backwards compat with drivers. Signed-off-by: Enrico Weigelt, metux IT consult --- hw/xwayland/xwayland-screen.c | 2 +- include/os.h | 4 +--- os/log.c | 8 +------- 3 files changed, 3 insertions(+), 11 deletions(-) diff --git a/hw/xwayland/xwayland-screen.c b/hw/xwayland/xwayland-screen.c index 26b3803b4..7d81c5094 100644 --- a/hw/xwayland/xwayland-screen.c +++ b/hw/xwayland/xwayland-screen.c @@ -91,7 +91,7 @@ xwl_give_up(const char *f, ...) va_list args; va_start(args, f); - VErrorFSigSafe(f, args); + VErrorF(f, args); va_end(args); CloseWellKnownConnections(); diff --git a/include/os.h b/include/os.h index 440627f6b..cdf970b45 100644 --- a/include/os.h +++ b/include/os.h @@ -370,9 +370,6 @@ _X_ATTRIBUTE_PRINTF(1, 0); extern _X_EXPORT void ErrorF(const char *f, ...) _X_ATTRIBUTE_PRINTF(1, 2); -extern _X_EXPORT void -VErrorFSigSafe(const char *f, va_list args) -_X_ATTRIBUTE_PRINTF(1, 0); void LogPrintMarkers(void); @@ -389,5 +386,6 @@ typedef _sigset_t sigset_t; #define LogVMessageVerbSigSafe(...) LogVMessageVerb(__VA_ARGS__) #define LogMessageVerbSigSafe(...) LogMessageVerb(__VA_ARGS__) #define ErrorFSigSafe(...) ErrorF(__VA_ARGS__) +#define VErrorFSigSafe(...) VErrorF(__VA_ARGS__) #endif /* OS_H */ diff --git a/os/log.c b/os/log.c index f46b294cd..e6a66a5bc 100644 --- a/os/log.c +++ b/os/log.c @@ -882,7 +882,7 @@ FatalError(const char *f, ...) va_end(apple_args); } #endif - VErrorFSigSafe(f, args); + VErrorF(f, args); va_end(args); ErrorF("\n"); if (!beenhere) @@ -915,12 +915,6 @@ ErrorF(const char *f, ...) va_end(args); } -void -VErrorFSigSafe(const char *f, va_list args) -{ - LogVMessageVerb(X_ERROR, -1, f, args); -} - void LogPrintMarkers(void) {