From: Yu Watanabe Date: Fri, 7 Apr 2023 09:44:22 +0000 (+0900) Subject: update-utmp: update log message X-Git-Tag: v254-rc1~391^2~3 X-Git-Url: http://git.ipfire.org/?a=commitdiff_plain;h=87ae54533c6ad7047a152b7238f682eda334a9e0;p=thirdparty%2Fsystemd.git update-utmp: update log message --- diff --git a/src/update-utmp/update-utmp.c b/src/update-utmp/update-utmp.c index 5656ca2761b..2f6d582da92 100644 --- a/src/update-utmp/update-utmp.c +++ b/src/update-utmp/update-utmp.c @@ -165,10 +165,9 @@ static int on_runlevel(int argc, char *argv[], void *userdata) { /* First, get last runlevel */ r = utmp_get_runlevel(&previous, NULL); - if (r < 0) { if (!IN_SET(r, -ESRCH, -ENOENT)) - return log_error_errno(r, "Failed to get current runlevel: %m"); + return log_error_errno(r, "Failed to get the last runlevel from utmp: %m"); previous = 0; } @@ -178,7 +177,7 @@ static int on_runlevel(int argc, char *argv[], void *userdata) { if (runlevel < 0) return runlevel; if (runlevel == 0) { - log_warning("Failed to get new runlevel, utmp update skipped."); + log_warning("Failed to get the current runlevel, utmp update skipped."); return 0; }