From: Yu Watanabe Date: Mon, 7 May 2018 01:16:04 +0000 (+0900) Subject: login: do not wall message on cancelling shutdown when Manager.enable_wall_messages... X-Git-Url: https://www.chiark.greenend.org.uk/ucgi/~ianmdlvl/git?a=commitdiff_plain;h=f6bdcb639582b5025266fb85465f74ffb7b2cca8;p=elogind.git login: do not wall message on cancelling shutdown when Manager.enable_wall_messages is false Fixes #8904. (cherry picked from commit 6e78fa4afd474dae984f3ee4a8477c623296a519) --- diff --git a/src/login/logind-dbus.c b/src/login/logind-dbus.c index f444ad9b4..e67708b30 100644 --- a/src/login/logind-dbus.c +++ b/src/login/logind-dbus.c @@ -2243,7 +2243,7 @@ static int method_cancel_scheduled_shutdown(sd_bus_message *message, void *userd cancelled = m->scheduled_shutdown_type != NULL; reset_scheduled_shutdown(m); - if (cancelled) { + if (cancelled && m->enable_wall_messages) { _cleanup_(sd_bus_creds_unrefp) sd_bus_creds *creds = NULL; const char *tty = NULL; uid_t uid = 0;