From 5b714f05f87831e3e930af04649f853d5efb9902 Mon Sep 17 00:00:00 2001 From: Ikalco <73481042+ikalco@users.noreply.github.com> Date: Wed, 18 Dec 2024 19:56:01 -0600 Subject: internal: Make static analysis more happy (#8767) * make functions used in 1 file static * fix invalid substr param -1 * give default initializer to borderGradier * move RASSERT from printf to std::print --- src/Compositor.cpp | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) (limited to 'src/Compositor.cpp') diff --git a/src/Compositor.cpp b/src/Compositor.cpp index dea8cddf..ba723bdc 100644 --- a/src/Compositor.cpp +++ b/src/Compositor.cpp @@ -50,7 +50,7 @@ using namespace Hyprutils::String; using namespace Aquamarine; -int handleCritSignal(int signo, void* data) { +static int handleCritSignal(int signo, void* data) { Debug::log(LOG, "Hyprland received signal {}", signo); if (signo == SIGTERM || signo == SIGINT || signo == SIGKILL) @@ -59,7 +59,7 @@ int handleCritSignal(int signo, void* data) { return 0; } -void handleUnrecoverableSignal(int sig) { +static void handleUnrecoverableSignal(int sig) { // remove our handlers signal(SIGABRT, SIG_DFL); @@ -83,7 +83,7 @@ void handleUnrecoverableSignal(int sig) { abort(); } -void handleUserSignal(int sig) { +static void handleUserSignal(int sig) { if (sig == SIGUSR1) { // means we have to unwind a timed out event throw std::exception(); @@ -103,7 +103,7 @@ static eLogLevel aqLevelToHl(Aquamarine::eBackendLogLevel level) { return NONE; } -void aqLog(Aquamarine::eBackendLogLevel level, std::string msg) { +static void aqLog(Aquamarine::eBackendLogLevel level, std::string msg) { Debug::log(aqLevelToHl(level), "[AQ] {}", msg); } -- cgit v1.2.3