1
1
mirror of https://github.com/systemd/systemd-stable.git synced 2025-01-21 18:03:41 +03:00

sulogin: use DEFINE_MAIN_FUNCTION()

Let's use DEFINE_MAIN_FUNCTION() as the other commands for consistency.

This commit should be no functional change.
This commit is contained in:
HATAYAMA Daisuke 2023-02-14 22:10:13 -05:00
parent e8dc52766e
commit 2ffbf44344

View File

@ -14,6 +14,7 @@
#include "def.h"
#include "env-util.h"
#include "log.h"
#include "main-func.h"
#include "process-util.h"
#include "signal-util.h"
#include "special.h"
@ -86,7 +87,7 @@ static void print_mode(const char* mode) {
fflush(stdout);
}
int main(int argc, char *argv[]) {
static int run(int argc, char *argv[]) {
const char* sulogin_cmdline[] = {
SULOGIN,
NULL, /* --force */
@ -115,5 +116,7 @@ int main(int argc, char *argv[]) {
r = start_default_target(bus);
}
return r >= 0 ? EXIT_SUCCESS : EXIT_FAILURE;
return r;
}
DEFINE_MAIN_FUNCTION(run);