aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorSam James <sam@gentoo.org>2023-01-25 04:02:17 +0000
committerMike Frysinger <vapier@gentoo.org>2023-01-25 00:50:15 -0500
commit78c0693c50447f8211d8e645363afa62cef8b2e4 (patch)
tree7e6937cb4e24c5ea05909a04a2cfe0c1b18ea837
parentddf4a3a7a05ec09da8a9c218e6597a1e8385c2d4 (diff)
openrc-shutdown: mark stop_shutdown as noreturn, fix typo/indentation
For -Wmissing-noreturn.
-rw-r--r--src/openrc-shutdown/openrc-shutdown.c6
1 files changed, 3 insertions, 3 deletions
diff --git a/src/openrc-shutdown/openrc-shutdown.c b/src/openrc-shutdown/openrc-shutdown.c
index dddc749b..a2fae5f5 100644
--- a/src/openrc-shutdown/openrc-shutdown.c
+++ b/src/openrc-shutdown/openrc-shutdown.c
@@ -167,13 +167,13 @@ static void sleep_no_interrupt(int seconds)
duration = remaining;
}
-static void stop_shutdown(int sig)
+_noreturn static void stop_shutdown(int sig)
{
(void) sig;
unlink(nologin_file);
unlink(shutdown_pid);
-einfo("Shutdown canceled");
-exit(0);
+ einfo("Shutdown cancelled");
+ exit(0);
}
int main(int argc, char **argv)